[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] Reference for unit 'Classes' (#rtl)

TPersistent

[Properties (by Name)] [Methods (by Name)] [Events (by Name)]

Base class for streaming system and persistent properties.

Declaration

Source position: classesh.inc line 380

type TPersistent = class(TObject)

protected

  procedure AssignTo(); virtual;

  

Generic assignment function.

  procedure DefineProperties(); virtual;

  

Declare non-published properties that need to be streamed.

  function GetOwner; dynamic;

  

Returns the owner of the component.

public

  destructor Destroy; override;

  

Destroys the TPersistent instance.

  procedure Assign(); virtual;

  

Assign the contents of one class to another.

  function GetNamePath; virtual;

  

Returns a string that can be used to identify the class instance.

end;

Inheritance

TPersistent

  

Base class for streaming system and persistent properties.

|

TObject

  

Base class of all classes.

Description

TPersistent is the basic class for the streaming system. Since it is compiled in the {$M+} state, the compiler generates RTTI (Run-Time Type Information) for it and all classes that descend from it. This information can be used to stream all properties of classes.

It also introduces functionality to assign the contents of 2 classes to each other.

See also

TComponent

  

Base class for all components that need owner-owned functionality.

The latest version of this document can be found at lazarus-ccr.sourceforge.net.