MCTTokenInterface Class Reference

#include <ct/mcttokeninterface.h>

Link against: ctframework.lib

class MCTTokenInterface
Public Member Functions
IMPORT_C voidRelease()
pure virtual MCTToken &Token()
Protected Member Functions
pure virtual ~MCTTokenInterface()
virtual IMPORT_C voidDoRelease()

Detailed Description

The base class for all token interfaces.

This class provides functionality to interact with the token's reference counting framework. (Interfaces themselves are not reference counted, but the token must remain open while it has open interfaces.)

Since
v7.0

Constructor & Destructor Documentation

~MCTTokenInterface ( )

~MCTTokenInterface()[protected, inline, pure virtual]

The interface should be destroyed via the Release() function. Hence, this destructor is protected.

Destructor

Member Function Documentation

DoRelease ( )

IMPORT_C voidDoRelease()[protected, virtual]

This function should release the interface and all its owned resources.

It is called by Release(). The default implementation simply does a 'delete this'. If other behaviour is required (for instance to implement a reference counting system for the interfaces themselves, the interfaces can override this function.)

Release ( )

IMPORT_C voidRelease()

Destroys the object.

The interface should be destroyed via this method as the destructor is protected.

Also takes care of reference counting the token.

Token ( )

MCTToken &Token()[pure virtual]

Gets the associated token.

Returns: The associated token.