Version: 8.3.0
YACS::ENGINE::Observer Class Reference

Base class for observer in observer pattern. More...

#include <Dispatcher.hxx>

Inheritance diagram for YACS::ENGINE::Observer:

Public Member Functions

virtual void notifyObserver (Node *object, const std::string &event)
 
virtual void notifyObserver2 (Node *object, const std::string &event, void *something)
 
virtual ~Observer ()
 

Detailed Description

Base class for observer in observer pattern.

When an event occurs, a registered observer is notified by calling its notifyObserver method with 2 arguments : the object which has emitted the event and the event type. There is no more data. It's the responsability of the observer to request all needed information from the emitting object.

Definition at line 45 of file Dispatcher.hxx.

Constructor & Destructor Documentation

Observer::~Observer ( )
virtual

Definition at line 29 of file Dispatcher.cxx.

30 {
31 }

Member Function Documentation

void Observer::notifyObserver ( Node object,
const std::string &  event 
)
virtual

Reimplemented in YACS::HMI::SubjectNode, and PluginObserver.

Definition at line 33 of file Dispatcher.cxx.

References DEBTRACE.

34 {
35  DEBTRACE("notifyObserver " << event << object );
36 }
void Observer::notifyObserver2 ( Node object,
const std::string &  event,
void *  something 
)
virtual

Reimplemented in PluginObserver.

Definition at line 38 of file Dispatcher.cxx.

References DEBTRACE.

39 {
40  DEBTRACE("notifyObserver2 " << event << object );
41 }

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