Share via


SortedDictionary<TKey,TValue>.ValueCollection Konstruktor

Definisi

Menginisialisasi instans SortedDictionary<TKey,TValue>.ValueCollection baru kelas yang mencerminkan nilai dalam yang ditentukan SortedDictionary<TKey,TValue>.

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

Parameter

Pengecualian

dictionaryadalah null.

Keterangan

SortedDictionary<TKey,TValue>.ValueCollection bukan salinan statis; sebagai gantinyaSortedDictionary<TKey,TValue>.ValueCollection, mengacu kembali ke nilai dalam aslinyaSortedDictionary<TKey,TValue>. Oleh karena itu, perubahan pada SortedDictionary<TKey,TValue> terus tercermin dalam SortedDictionary<TKey,TValue>.ValueCollection.

Konstruktor ini adalah operasi O(1).

Berlaku untuk