Dictionary<TKey,TValue>.ICollection<KeyValuePair<TKey,TValue>>.CopyTo 메서드

정의

지정한 배열 인덱스부터 ICollection<T>의 요소를 KeyValuePair<TKey,TValue>형식의 배열에 복사합니다.

 virtual void System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<TKey,TValue>>.CopyTo(cli::array <System::Collections::Generic::KeyValuePair<TKey, TValue>> ^ array, int index) = System::Collections::Generic::ICollection<System::Collections::Generic::KeyValuePair<TKey, TValue>>::CopyTo;
void ICollection<KeyValuePair<TKey,TValue>>.CopyTo (System.Collections.Generic.KeyValuePair<TKey,TValue>[] array, int index);
abstract member System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<TKey,TValue>>.CopyTo : System.Collections.Generic.KeyValuePair<'Key, 'Value>[] * int -> unit
override this.System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<TKey,TValue>>.CopyTo : System.Collections.Generic.KeyValuePair<'Key, 'Value>[] * int -> unit
Sub CopyTo (array As KeyValuePair(Of TKey, TValue)(), index As Integer) Implements ICollection(Of KeyValuePair(Of TKey, TValue)).CopyTo

매개 변수

array
KeyValuePair<TKey,TValue>[]

ICollection<T>에서 복사한 KeyValuePair<TKey,TValue> 요소의 대상인 KeyValuePair<TKey,TValue> 형식의 1차원 배열입니다. 배열에는 0부터 시작하는 인덱스가 있어야 합니다.

index
Int32

array에서 복사가 시작되는 0부터 시작하는 인덱스입니다.

구현

예외

array이(가) null인 경우

index 가 0보다 작습니다.

소스 ICollection<T>의 요소 수가 대상 arrayindex부터 끝까지 사용 가능한 공간보다 큽니다.

적용 대상