/// <summary> /// Initializes a new instance of the KoderHack.MultiValueSortedDictionary<TKey,TValue>.ValueCollection /// class that reflects the values in the specified KoderHack.MultiValueSortedDictionary<TKey,TValue>. /// </summary> /// <param name="dictionary"> /// The KoderHack.MultiValueSortedDictionary<TKey,TValue> whose values /// are reflected in the new KoderHack.MultiValueSortedDictionary<TKey,TValue>.ValueCollection. /// </param> /// <exception cref="System.ArgumentNullException"> /// dictionary is null. /// </exception> public ValueCollection([NotNull] MultiValueSortedDictionary <TKey, TValue> dictionary) { if (dictionary == null) { throw new ArgumentNullException(); } _Dictionary = dictionary; //foreach (KeyValuePair<TKey, List<TValue>> pair in dictionary._SortedDictionary) // _values.AddRange(pair.Value); }
public Enumerator([NotNull] MultiValueSortedDictionary <TKey, TValue> dictionary) { if (dictionary == null) { throw new ArgumentNullException(nameof(dictionary)); } _Dictionary = dictionary; _Enumerator1 = dictionary._SortedDictionary.GetEnumerator(); _Enumerator2 = null; DefaultCurrent = new KeyValuePair <TKey, TValue>(default(TKey), default(TValue)); _Current = DefaultCurrent; //_Disposed = false; _Valid = true; }
internal Enumerator(MultiValueSortedDictionary <TKey, TValue> dictionary) { _Dictionary = dictionary; _Enumerator = new MultiValueSortedDictionary <TKey, TValue> .Enumerator(_Dictionary); }