Index   Main   Namespaces   Classes   Hierarchy   Annotated   Files   Compound   Global   Pages  
Public Types | Public Member Functions | Private Attributes

GtpCallback< ENGINE > Class Template Reference

Member function command handlers. More...

#include <GtpEngine.h>

Inheritance diagram for GtpCallback< ENGINE >:
Inheritance graph
[legend]

List of all members.

Public Types

typedef void(ENGINE::* Method )(GtpCommand &)
 Signature of the member function.

Public Member Functions

 GtpCallback (ENGINE *instance, typename GtpCallback< ENGINE >::Method method)
 ~GtpCallback () throw ()
void operator() (GtpCommand &)
 Execute the member function.

Private Attributes

ENGINE * m_instance
Method m_method

Detailed Description

template<class ENGINE>
class GtpCallback< ENGINE >

Member function command handlers.

For registering member functions in GtpEngine::Register().

Note:
Instances keep a pointer to the object containing the member function. If the object does is not a subclass of GtpEngine and registers only its own members, you have to make sure that the object's lifetime exceeds the lifetime of the GtpEngine.

Definition at line 504 of file GtpEngine.h.


Member Typedef Documentation

typedef void(ENGINE::* Method)(GtpCommand &)

Signature of the member function.

Definition at line 509 of file GtpEngine.h.


Constructor & Destructor Documentation

GtpCallback ( ENGINE *  instance,
typename GtpCallback< ENGINE >::Method  method 
)

Definition at line 526 of file GtpEngine.h.

~GtpCallback (  )  throw ()

Definition at line 534 of file GtpEngine.h.

References GtpCallback< ENGINE >::m_instance.


Member Function Documentation

void operator() ( GtpCommand cmd  )  [virtual]

Execute the member function.

Implements GtpCallbackBase.

Definition at line 542 of file GtpEngine.h.

References GtpCallback< ENGINE >::m_instance, and GtpCallback< ENGINE >::m_method.


Member Data Documentation

ENGINE* m_instance [private]
Method m_method [private]

Definition at line 522 of file GtpEngine.h.

Referenced by GtpCallback< ENGINE >::operator()().


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


Sun Mar 13 2011 Doxygen 1.7.1