Overload List
| # | Signature | Description |
|---|---|---|
| 1 | MatrixInt(TMtxInt Src) | Uses TMtxInt object as internal storage. |
| 2 | MatrixInt(Boolean FromObjectCache) | Constructor of the record. |
| 3 | MatrixInt(Int32 aRows, Int32 aCols) | Constructor of the record. |
| 4 | MatrixInt(Int32 aRows, Int32 aCols, TIntPrecision aPrecision) | Internally creates TMtxInt object without using object cache. |
Overload 1: MatrixInt(TMtxInt Src)
Uses TMtxInt object as internal storage.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | Src | TMtxInt | source TMtxInt |
Result: stored in self (calling object)
The resulting Vector will own Src object of TMtxInt type and will release it once Vector gets out of scope.
Overload 2: MatrixInt(Boolean FromObjectCache)
Constructor of the record.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | FromObjectCache | Boolean |
Result: stored in self (calling object)
Returns a Vector with internal TMtxInt object created from object cache (CreateIt), if FromObjectCache is True. Pass false to the constructor or do not call it at all, if the variable is a local variable. Object cache has limited size.
Overload 3: MatrixInt(Int32 aRows, Int32 aCols)
Constructor of the record.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | aRows | Int32 | |
| 2 | aCols | Int32 |
Result: stored in self (calling object)
Returns a Vector with internal TMtxInt object created explicitely with Length property set to aLength and IntPrecision property set to int32. Call this constructor, if the Vector type variable is a global variable with a long life span.
MatrixInt a;
MatrixInt b;
TMtxInt bvec;
a = MatrixInt.Create(true); //create from object cache via CreateIt
//this constructor can be omitted, because it is implicitly called
//the first time that the variable is used.
//However:
b = MatrixInt.Create(10);
//Similar to
bvec = TMtxInt.Create;
try
{
bvec.Size(10);
}
finally
{
bvec.Free; //b is freed on the exit from the procedure
}
Overload 4: MatrixInt(Int32 aRows, Int32 aCols, TIntPrecision aPrecision)
Internally creates TMtxInt object without using object cache.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | aRows | Int32 | |
| 2 | aCols | Int32 | |
| 3 | aPrecision | TIntPrecision |
Result: stored in self (calling object)
Creates TMtxInt object without using object cache. Suitable for declaring global variables.