IROObjectRetainer

Overview

The IROObjectRetainer interface is used by the Remoting SDK to exactly control the lifetime of an object.

For an example of how to use this interface, see the [HTTP ChatBonjourDiscovery sample, where the TROEventReceiver is used to retain aUserInfo.

Location


Required Methods


IsRetained

Returns true if anObject is retained by Self.

function IsRetained(const anObject: TObject): Boolean

Parameters:

  • anObject: Object to check

ReleaseObject

Takes away the hold of anObject set by RetainObject.

procedure ReleaseObject(const anObject: TObject)

Parameters:

  • anObject: Object to release

RetainObject

Sets the hold of anObject.

procedure RetainObject(const anObject: TObject)

Parameters:

  • anObject: Object to hold