You are here: Symbol Reference > MtxVec Namespace > Classes > TMtx Class > public > Adopt Method > TMtx.Adopt Method (PAPointer, integer, integer, boolean, boolean)
MtxVec VCL
ContentsIndex
PreviousUpNext
TMtx.Adopt Method (PAPointer, integer, integer, boolean, boolean)

Adopts a pointer to one dimensional array.

Pascal
procedure Adopt(AArray: PAPointer; ARows: integer; ACols: integer; aIsComplex: boolean; aIsDouble: boolean); overload;

Addopts a pointer to AArray array. The method sets the calling matrix FlaotPrecision property to aFloatPrecision, Rows to ARows, Cols to ACols and Values1D and CValues1D to Pointer(AArray). 

Notes:

  • Required to call the Disown method, before freeing the object
  • do not resize the vector
  • do not call any routines relying on Lapack when "Core edition" is used (not linking dlls), because Lapack will assume that adopted memory is a dynamic array and will modify array index -2.
Copyright (c) 1999-2025 by Dew Research. All rights reserved.
What do you think about this topic? Send feedback!