System::Array::CopyTo method

Array::CopyTo(ArrayPtr<T>, int) method

Copies all elements of the current array to the specified destination array. Elements are inserted into destination array starting at index specified by arrayIndex argument.

virtual void System::Array<T>::CopyTo(ArrayPtr<T> arr, int arrayIndex) override
ParameterTypeDescription
arrArrayPtr<T>Destination array
arrayIndexintIndex in destination array to start inserting copied items at

See Also

Array::CopyTo(const ArrayPtr<DstType>&, int64_t) const method

Copies all elements of the current array to the specified destination array. Elements are inserted into the destination array starting at index specified by dstIndex argument.

template<typename DstType> void System::Array<T>::CopyTo(const ArrayPtr<DstType> &dstArray, int64_t dstIndex) const
ParameterDescription
DstTypeType of elements in destination array
ParameterTypeDescription
dstArrayconst ArrayPtr<DstType>&Destination array
dstIndexint64_tIndex in destination array to start inserting copied items at

See Also

Array::CopyTo(const ArrayPtr<DstType>&, int64_t, int64_t, int64_t) const method

Copies a specified number of elements from the current array starting at specified position to specified destination array. Elements are inserted into the destination array starting at index specified by dstIndex argument.

template<typename DstType> void System::Array<T>::CopyTo(const ArrayPtr<DstType> &dstArray, int64_t srcIndex, int64_t dstIndex, int64_t count) const
ParameterDescription
DstTypeType of elements in destination array
ParameterTypeDescription
dstArrayconst ArrayPtr<DstType>&Destination array
srcIndexint64_tIndex in source array to start copying items at
dstIndexint64_tIndex in destination array to start inserting copied items at
countint64_tNumber of elements to copy

See Also

Array::CopyTo(const System::Details::ArrayView<DstType>&, int64_t) const method

Copies all elements of the current array to the specified destination array view. Elements are inserted into the destination array view starting at index specified by dstIndex argument.

template<typename DstType> void System::Array<T>::CopyTo(const System::Details::ArrayView<DstType> &dstArray, int64_t dstIndex) const
ParameterDescription
DstTypeType of elements in destination array view
ParameterTypeDescription
dstArrayconst System::Details::ArrayView<DstType>&Destination array view
dstIndexint64_tIndex in destination array view to start inserting copied items at

See Also

Array::CopyTo(const System::Details::ArrayView<DstType>&, int64_t, int64_t, int64_t) const method

Copies a specified number of elements from the current array starting at specified position to specified destination array view. Elements are inserted into the destination array view starting at index specified by dstIndex argument.

template<typename DstType> void System::Array<T>::CopyTo(const System::Details::ArrayView<DstType> &dstArray, int64_t srcIndex, int64_t dstIndex, int64_t count) const
ParameterDescription
DstTypeType of elements in destination array view
ParameterTypeDescription
dstArrayconst System::Details::ArrayView<DstType>&Destination array view
srcIndexint64_tIndex in source array to start copying items at
dstIndexint64_tIndex in destination array view to start inserting copied items at
countint64_tNumber of elements to copy

See Also