RAD Studio VCL Reference
|
Copies the contents of a System::DynamicArray to the specified System::DynamicArray.
function Copy: DynamicArray<T>; procedure Copy(var dst: DynamicArray<T>);
DynamicArray<T> Copy() const; void Copy(DynamicArray<T> & dst) const;
Use System::DynamicArray::Copy to make a copy of a dynamic array. Dynamic arrays are reference counted. Therefore assigning one to another simply copies the reference, not the data. The System::DynamicArray::Copy method, on the other hand, makes a separate copy of the dynamic array. The original contents of the destination array are discarded.
The following code copies the contents of i_array into temp; temp and i_array must be of the same System::DynamicArray type.
temp = i_array.Copy();
Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
|
What do you think about this topic? Send feedback!
|