Overload List
| # | Signature | Description |
|---|---|---|
| 1 | function Concat(const Src: TVecInt[]): TVecInt; | Concatenates an array of TVecInt objects. |
| 2 | function Concat(Index: Integer; const Src: TVecInt[]): TVecInt; | Copies the contents of all TVecInt objects from the Src array to the calling vector elements, starting with at Index. |
Overload 1: function Concat(const Src: TVecInt[]): TVecInt;
Concatenates an array of TVecInt objects.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | Src | TVecInt[] |
Result: stored in self (calling object), returns self for chaining
Concatenates an array of TVecInt objects. The method copies the contents of all TVecInt objects from the Src array to the calling object. The TMtxVecBase.Length and TMtxVec.Complex properties of the calling vector are set implicitly. An exception is raised, if Complex properties of TVecInt objects do not match.
var a,b,c,d: TVecInt;
begin
CreateIt(a,b,c,d);
try
a.SetIt([1,2,3]);
b.Copy(a);
c.Concat([a,b]); // c = [1,2,3,1,2,3]
d.Size(10);
d.SetZero(0,4);
d.Concat(4,[c]); // d = [0,0,0,0,1,2,3,1,2,3]
finally
FreeIt(a,b,c,d);
end;
end;
Overload 2: function Concat(Index: Integer; const Src: TVecInt[]): TVecInt;
Copies the contents of all TVecInt objects from the Src array to the calling vector elements, starting with at Index.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | Index | Integer | start index |
| 2 | Src | TVecInt[] |
Result: stored in self (calling object), returns self for chaining
The TMtxVecBase.Length and TMtxVec.Complex properties of the calling vector must be set explicitly. An exception is raised, if Complex properties of TVecInt objects do not match or if the sum of Length's exceeds the Length property of the calling object.