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


This method tells an object to dispose of itself.


Source position: intuition.pas line 1765

const OM_DISPOSE = OM_Dummy + 2;


This method instructs an object to delete itself. The rootclass dispatcher's OM_DISPOSE method decrements the true class's internal count of instances of true class. The return value for this method is not explicitly defined.

This method uses the default Boopsi message.

Applications should not call this method directly. Instead they should use the function DisposeObject().

For the OM_DISPOSE method, an object should do the following:

Free any additional resources the object explicitly allocated itself in the OM_NEW method (this does not include the instance data).

Pass the message up to the superclass, which will eventually reach rootclass, which will free the instance data allocated for the object.

If a class does not allocate any extra resources when it creates an object, it can defer all OM_DISPOSE processing to its superclass.

See also





Perform method on object coerced to superclass.

Documentation generated on: 2017-01-10