SortedSet<T>.ICollection<T>.Add(T) 메서드

정의

ICollection<T> 개체에 항목을 추가합니다.

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

매개 변수

item
T

ICollection<T> 개체에 추가할 개체입니다.

구현

예외

ICollection<T>이 읽기 전용인 경우

설명

이 멤버는 명시적 인터페이스 멤버 구현이며, SortedSet<T> 인스턴스가 ICollection<T> 인터페이스로 캐스팅된 경우에만 사용할 수 있습니다.

가 보다 작으면 Count 이 메서드는 작업입니다O(1).Capacity 새 요소를 수용하기 위해 용량을 늘려야 하는 경우 이 메서드는 작업이 됩니다 O(n) . 여기서 n 는 입니다 Count.

적용 대상