VR-Forces 4.8 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Private Types | Private Member Functions | Private Attributes | Friends
DtCallbackConnection Class Reference

Represents the connection of a specific callback to a DtCallbackListT. More...

Public Member Functions

 DtCallbackConnection ()
 Default constructor. More...
 
bool disconnect ()
 Disconnect the connection. More...
 

Private Types

typedef boost::function< bool()> DisconnectFunctionType
 

Private Member Functions

 DtCallbackConnection (const DisconnectFunctionType &func)
 

Private Attributes

DisconnectFunctionType myDisconnectFunction
 

Friends

template<typename Callback >
class DtCallbackListT
 

Detailed Description

Represents the connection of a specific callback to a DtCallbackListT.

Saving a DtCallbackConnection returned from DtCallbackListT::addCallback allows you to disconnect the callback without having to remember what DtCallbackListT it was connected to or what parameters were used to connect it It is also more efficient than calling removeCallback.

Member Typedef Documentation

typedef boost::function<bool()> DtCallbackConnection::DisconnectFunctionType
private

Constructor & Destructor Documentation

DtCallbackConnection::DtCallbackConnection ( )
inline

Default constructor.

DtCallbackConnection::DtCallbackConnection ( const DisconnectFunctionType func)
inlineexplicitprivate

Member Function Documentation

bool DtCallbackConnection::disconnect ( )
inline

Disconnect the connection.

Can be called multiple times. Can be called on a default constructed object.

Returns
Whether the disconnected callback was the last callback in the list.

Friends And Related Function Documentation

template<typename Callback >
friend class DtCallbackListT
friend

Member Data Documentation

DisconnectFunctionType DtCallbackConnection::myDisconnectFunction
private

The documentation for this class was generated from the following file:

Document ID: Generated on Thu Aug 27 10:56:05 EDT 2020 from SVN revision 217100
Copyright © 2005-2020 MAK Technologies. All Rights Reserved (www.mak.com)