System::Collections::Generic::List::CopyTo metod

List::CopyTo(const System::ArrayPtr<T>&) method

Kopierar alla element till befintliga array‑element.

void System::Collections::Generic::List<T>::CopyTo(const System::ArrayPtr<T> &array)
ParameterTypBeskrivning
arrayconst System::ArrayPtr<T>&Array för att kopiera element till.

Se även

List::CopyTo(int, const System::ArrayPtr<T>&, int, int) method

Kopierar element med start från det angivna indexet till befintliga array‑element.

void System::Collections::Generic::List<T>::CopyTo(int index, const System::ArrayPtr<T> &array, int arrayIndex, int count)
ParameterTypBeskrivning
indexintEtt 0-baserat index för elementet i listan som representeras av det aktuella objektet att börja kopiera från
arrayconst System::ArrayPtr<T>&Array för att kopiera element till.
arrayIndexintStartposition i destinationsarrayen.
countintAntal element att kopiera.

Se även

List::CopyTo(System::ArrayPtr<T>, int) method

Kopierar listelement till befintliga array‑element.

void System::Collections::Generic::List<T>::CopyTo(System::ArrayPtr<T> array, int arrayIndex) override
ParameterTypBeskrivning
arraySystem::ArrayPtr<T>Målararray.
arrayIndexintStartindex för destinationsarrayen.

Se även