Class TWrapper

DescriptionHierarchyFieldsMethodsProperties

Unit

Declaration

type TWrapper = class(TInterfacedObject)

Description

Base class of any wrapped engine class.
This class stores a reference to a foreign object and is able to free additional wrapper objects created by an inheriting class.

Hierarchy

Overview

Methods

Public constructor Create(NReference: Pointer);
Public destructor Destroy; override;
Public procedure Acquire(Other: TObject); inline;

Properties

Public property Reference: Pointer read FReference;

Description

Methods

Public constructor Create(NReference: Pointer);

Constructor. Only used internally.

Public destructor Destroy; override;

Destructor.
Frees any objects Acquire 'd before.

Public procedure Acquire(Other: TObject); inline;

Adds an object to the internal deletion list.
Whenever a wrapped object returns another object which is internally owned by the returning C++ class, (e.g. a method like TVideoDriver.GetTexture), an additional TWrapper object is created for the returned reference. To simulate the behaviour of Irrlicht (non-'create'd objects are handled by the engine), the returning class Acquire 's he new wrapper object. Upon destruction of the Acquire 'ing class, the object will be deleted as well.

Properties

Public property Reference: Pointer read FReference;

The native reference to the wrapped object.
Usually used internally.


Generated by PasDoc 0.12.1 on 2012-09-14 17:32:22