Dictionary<TKey,TValue>.ICollection<KeyValuePair<TKey,TValue>>.CopyTo Método
Definição
Importante
Algumas informações dizem respeito a um produto pré-lançado que pode ser substancialmente modificado antes de ser lançado. A Microsoft não faz garantias, de forma expressa ou implícita, em relação à informação aqui apresentada.
Copia os elementos de para ICollection<T> um array do tipo KeyValuePair<TKey,TValue>, começando no índice especificado do array.
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
Parâmetros
- array
- KeyValuePair<TKey,TValue>[]
O array unidimensional de tipo KeyValuePair<TKey,TValue> que é o destino dos KeyValuePair<TKey,TValue> elementos copiados do ICollection<T>. O array deve ter indexação baseada em zero.
- index
- Int32
O índice baseado em zero em array onde começa a cópia.
Implementações
Exceções
array é null.
index é inferior a 0.
O número de elementos na fonte ICollection<T> é maior do que o espaço disponível de index até ao fim do destino array.