ReadOnlyDictionary<TKey,TValue>.ValueCollection.ICollection<TValue>.Add Metoda

Definicja

Zgłasza NotSupportedException wyjątek we wszystkich przypadkach.

 virtual void System.Collections.Generic.ICollection<TValue>.Add(TValue item) = System::Collections::Generic::ICollection<TValue>::Add;
void ICollection<TValue>.Add (TValue item);
abstract member System.Collections.Generic.ICollection<TValue>.Add : 'Value -> unit
override this.System.Collections.Generic.ICollection<TValue>.Add : 'Value -> unit
Sub Add (item As TValue) Implements ICollection(Of TValue).Add

Parametry

item
TValue

Obiekt, który zostanie dodany do kolekcji.

Implementuje

Wyjątki

We wszystkich przypadkach.

Uwagi

Ten element jest jawną implementacją członków. Można go używać tylko wtedy, gdy ReadOnlyDictionary<TKey,TValue>.ValueCollection wystąpienie jest rzutowe do interfejsu ICollection<T> . Interfejs ICollection<T> określa, że Add metoda powinna zgłosić NotSupportedException wyjątek, jeśli kolekcja implementujący interfejs jest tylko do odczytu.

Dotyczy