FireDAC.Stan.Util.FDFreeAndNil
Delphi
procedure FDFreeAndNil(var AObj);
C++
extern DELPHI_PACKAGE void __fastcall FDFreeAndNil(void *AObj);
Properties
Type | Visibility | Source | Unit | Parent |
---|---|---|---|---|
procedure function |
public | FireDAC.Stan.Util.pas FireDAC.Stan.Util.hpp |
FireDAC.Stan.Util | FireDAC.Stan.Util |
Description
Frees an object reference and replaces the reference with nil (Delphi) or NULL (C++).
Use FDFreeAndNil to ensure that a variable is nil (Delphi) or NULL (C++) after you free the object it references. Pass any variable that represents an object as the AObj
parameter. The behavior differs for ARC and non-ARC platforms:
Warning:
AObj
must be an instance of a TObject descendant.