SortedDictionary<TKey,TValue>.KeyCollection Constructor

Definitie

Initialiseert een nieuw exemplaar van de SortedDictionary<TKey,TValue>.KeyCollection klasse die de sleutels in de opgegeven SortedDictionary<TKey,TValue>klasse weerspiegelt.

public:
 KeyCollection(System::Collections::Generic::SortedDictionary<TKey, TValue> ^ dictionary);
public KeyCollection(System.Collections.Generic.SortedDictionary<TKey,TValue> dictionary);
new System.Collections.Generic.SortedDictionary<'Key, 'Value>.KeyCollection : System.Collections.Generic.SortedDictionary<'Key, 'Value> -> System.Collections.Generic.SortedDictionary<'Key, 'Value>.KeyCollection
Public Sub New (dictionary As SortedDictionary(Of TKey, TValue))

Parameters

Uitzonderingen

dictionary is null.

Opmerkingen

Het SortedDictionary<TKey,TValue>.KeyCollection is geen statische kopie; in plaats daarvan verwijst de SortedDictionary<TKey,TValue>.KeyCollection waarde terug naar de sleutels in het origineel SortedDictionary<TKey,TValue>. Daarom blijven wijzigingen in de wijzigingen in de SortedDictionary<TKey,TValue>SortedDictionary<TKey,TValue>.KeyCollection.

Deze constructor is een O(1)-bewerking.

Van toepassing op