CodeAttributeArgumentCollection.CopyTo(CodeAttributeArgument[], Int32) 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 objetos da coleção para uma instância unidimensional Array começando no índice especificado.
public:
void CopyTo(cli::array <System::CodeDom::CodeAttributeArgument ^> ^ array, int index);
public void CopyTo(System.CodeDom.CodeAttributeArgument[] array, int index);
member this.CopyTo : System.CodeDom.CodeAttributeArgument[] * int -> unit
Public Sub CopyTo (array As CodeAttributeArgument(), index As Integer)
Parâmetros
- array
- CodeAttributeArgument[]
O unidimensional Array que é o destino dos valores copiados da coleção.
- index
- Int32
O índice do array onde começar a inserir.
Exceções
O array de destino é multidimensional.
-ou-
O número de elementos no CodeAttributeArgumentCollection é maior do que o espaço disponível entre o índice do array alvo especificado pelo index parâmetro e o final do array.
O array parâmetro é null.
O index parâmetro é inferior ao índice mínimo do array-alvo.
Exemplos
O exemplo seguinte demonstra como copiar o conteúdo de um CodeAttributeArgumentCollection objeto para um CodeAttributeArgument array que começa num valor de índice especificado.
// Copies the contents of the collection beginning at index 0,
// to the specified CodeAttributeArgument array.
// 'arguments' is a CodeAttributeArgument array.
collection.CopyTo( arguments, 0 );
' Copies the contents of the collection beginning at index 0,
' to the specified CodeAttributeArgument array.
' 'arguments' is a CodeAttributeArgument array.
collection.CopyTo(arguments, 0)