You are here: Symbol Reference > AbstractMtxVecInt Namespace > Classes > TMtxVecInt Class > public > Copy Method > TMtxVecInt.Copy Method (TMtxVecInt)
MtxVec VCL
ContentsIndex
PreviousUpNext
TMtxVecInt.Copy Method (TMtxVecInt)

Copy object values.

Pascal
function Copy(const Src: TMtxVecInt): TMtxVecInt; overload;

Copy each of Vec elements to the calling object. The Size property of the calling object is set implicitly to match Vec object.

uses MtxVecInt; procedure Example; var a,b: TVecInt; begin a := TVecInt.Create(); b := TVecInt.Create(); try a.SetIt([1,2,3,4]); // a = [1,2,3,4] b.Copy(a); // b = [1,2,3,4] finally a.Free; b.Free; end; end;
Examples on GitHub
Copyright (c) 1999-2024 by Dew Research. All rights reserved.
What do you think about this topic? Send feedback!