UnsafeListDictionary<TKey, TValue> Class
This dictionary doesn't ensure the items are unique. For instance, you can use it to create a list of values to serialize without spending time validating the items.
public sealed class UnsafeListDictionary<TKey, TValue> : ICollection<KeyValuePair<TKey, TValue>>, IDictionary<TKey, TValue>, IEnumerable<KeyValuePair<TKey, TValue>>, IReadOnlyCollection<KeyValuePair<TKey, TValue>>, IReadOnlyDictionary<TKey, TValue>, IEnumerable where TKey : notnullType parameters
TKeyTValue
- Implements
Nested types
| Name | Description |
|---|---|
| UnsafeListDictionary<TKey, TValue>.KeyCollection | |
| UnsafeListDictionary<TKey, TValue>.ValueCollection |
Constructors
UnsafeListDictionary overloads
UnsafeListDictionary()
UnsafeListDictionary.cspublic UnsafeListDictionary()No documentation is available.
UnsafeListDictionary(IEnumerable<KeyValuePair<TKey, TValue>>)
UnsafeListDictionary.cspublic UnsafeListDictionary(IEnumerable<KeyValuePair<TKey, TValue>> items)Parameters
No documentation is available.
UnsafeListDictionary(IEnumerable<KeyValuePair<TKey, TValue>>, IEqualityComparer<TKey>?)
UnsafeListDictionary.cspublic UnsafeListDictionary(IEnumerable<KeyValuePair<TKey, TValue>> items, IEqualityComparer<TKey>? comparer)Parameters
No documentation is available.
UnsafeListDictionary(IEqualityComparer<TKey>?)
UnsafeListDictionary.cspublic UnsafeListDictionary(IEqualityComparer<TKey>? comparer)Parameters
comparerIEqualityComparer<TKey>?
No documentation is available.
UnsafeListDictionary(int)
UnsafeListDictionary.csUnsafeListDictionary(int, IEqualityComparer<TKey>?)
UnsafeListDictionary.cspublic UnsafeListDictionary(int capacity, IEqualityComparer<TKey>? comparer)Parameters
capacityintcomparerIEqualityComparer<TKey>?
No documentation is available.
Properties
| Name | Description |
|---|---|
| Comparer | Gets the comparer used to compare keys. |
| Count | |
| Keys | Gets a read-only view of the keys, in insertion order. The view reflects later changes to the dictionary. |
| System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<TKey,TValue>>.IsReadOnly | |
| System.Collections.Generic.IDictionary<TKey,TValue>.Keys | |
| System.Collections.Generic.IDictionary<TKey,TValue>.Values | |
| System.Collections.Generic.IReadOnlyDictionary<TKey,TValue>.Keys | |
| System.Collections.Generic.IReadOnlyDictionary<TKey,TValue>.Values | |
| Values | Gets a read-only view of the values, in insertion order. The view reflects later changes to the dictionary. |
Comparer
UnsafeListDictionary.csGets the comparer used to compare keys.
public IEqualityComparer<TKey> Comparer { get; }Property value
Gets a read-only view of the keys, in insertion order. The view reflects later changes to the dictionary.
public UnsafeListDictionary<TKey, TValue>.KeyCollection Keys { get; }Property value
System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<TKey,TValue>>.IsReadOnly
UnsafeListDictionary.csbool ICollection<KeyValuePair<TKey, TValue>>.IsReadOnly { get; }Property value
No documentation is available.
System.Collections.Generic.IDictionary<TKey,TValue>.Keys
UnsafeListDictionary.csICollection<TKey> IDictionary<TKey, TValue>.Keys { get; }Property value
No documentation is available.
System.Collections.Generic.IDictionary<TKey,TValue>.Values
UnsafeListDictionary.csICollection<TValue> IDictionary<TKey, TValue>.Values { get; }Property value
No documentation is available.
System.Collections.Generic.IReadOnlyDictionary<TKey,TValue>.Keys
UnsafeListDictionary.csIEnumerable<TKey> IReadOnlyDictionary<TKey, TValue>.Keys { get; }Property value
No documentation is available.
System.Collections.Generic.IReadOnlyDictionary<TKey,TValue>.Values
UnsafeListDictionary.csIEnumerable<TValue> IReadOnlyDictionary<TKey, TValue>.Values { get; }Property value
No documentation is available.
Values
UnsafeListDictionary.csGets a read-only view of the values, in insertion order. The view reflects later changes to the dictionary.
public UnsafeListDictionary<TKey, TValue>.ValueCollection Values { get; }Property value
Indexers
| Name | Description |
|---|---|
| this[TKey] |
this[TKey]
UnsafeListDictionary.cspublic TValue this[TKey key] { get; set; }Parameters
keyTKey
Property value
TValue
No documentation is available.
Methods
Add overloads
Add(KeyValuePair<TKey, TValue>)
UnsafeListDictionary.csAdd(TKey, TValue)
UnsafeListDictionary.csAddRange(IEnumerable<KeyValuePair<TKey, TValue>>)
UnsafeListDictionary.cspublic void AddRange(IEnumerable<KeyValuePair<TKey, TValue>> items)Parameters
No documentation is available.
Clear()
UnsafeListDictionary.cspublic void Clear()No documentation is available.
Contains(KeyValuePair<TKey, TValue>)
UnsafeListDictionary.cspublic bool Contains(KeyValuePair<TKey, TValue> item)No documentation is available.
ContainsKey(TKey)
UnsafeListDictionary.csGetEnumerator()
UnsafeListDictionary.cspublic List<KeyValuePair<TKey, TValue>>.Enumerator GetEnumerator()No documentation is available.
Remove overloads
Remove(KeyValuePair<TKey, TValue>)
UnsafeListDictionary.cspublic bool Remove(KeyValuePair<TKey, TValue> item)No documentation is available.
Remove(TKey)
UnsafeListDictionary.csSystem.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<TKey,TValue>>.CopyTo(KeyValuePair<TKey, TValue>[], int)
UnsafeListDictionary.csvoid ICollection<KeyValuePair<TKey, TValue>>.CopyTo(KeyValuePair<TKey, TValue>[] array, int arrayIndex)Parameters
arrayKeyValuePair<TKey, TValue>[]arrayIndexint
No documentation is available.
System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<TKey,TValue>>.GetEnumerator()
UnsafeListDictionary.csIEnumerator<KeyValuePair<TKey, TValue>> IEnumerable<KeyValuePair<TKey, TValue>>.GetEnumerator()No documentation is available.