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

Adopts a pointer to one dimensional array.

Pascal
procedure Adopt(AArray: PAPointer; ALength: integer; aFloatPrecision: TMtxFloatPrecision); overload;

Adopts a pointer to AArray array. The method sets the calling vector FloatPrecision property to aFloatPrecision, 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!