#include <ColCOWS_EventHandler.hh>
Collaboration diagram for ColCOWS::EventHandler:
The EventHandler allows the user to catch and react to events of workspace life-cycle (activation, connection, disconnection).
The user must declare a class inheriting from EventHandler and implement the event methods called by the ColCOWS nodes. Then he must register his event handler to the node with Node::setEventHandler( ... ).
Definition at line 53 of file ColCOWS_EventHandler.hh.
Public Member Functions | |
EventHandler () | |
constructor | |
virtual | ~EventHandler () |
destructor | |
unsigned int | getKey () const |
get key of this event handler in its event handler manager ( 0 => not registred to an event handler manager ) | |
void | setKey (unsigned int key) |
set key of this event handler in its event handler manager ( 0 => not registred to an event handler manager ) | |
EventHandlerManager * | getEventHandlerManager () const |
get event handler manager pointer | |
void | setEventHandlerManager (EventHandlerManager *event_handler_manager) |
set event handler manager pointer | |
Node * | getColCOWSNode () const |
get ColCOWS Node pointer | |
Protected Member Functions | |
virtual void | onActivation () |
treatment on the activation of the workspace | |
virtual void | onDeactivation () |
treatment on the deactivation of the workspace | |
virtual void | onConnection (unsigned long num_connection, bool initiator) |
treatment on the connection of a workspace | |
virtual void | onDisconnection (unsigned long num_connection) |
treatment on a disconnection | |
Protected Attributes | |
EventHandlerManager * | _event_handler_manager |
associated EventHandlerManager | |
unsigned int | _key |
key in the event handler manager | |
Friends | |
class | EventHandlerManager |