Garmin Fleet Management Controller  2.19.0
EventListener Class Referenceabstract

Base class for objects that take action in response to an Event being posted. More...

#include <EventListener.h>

+ Inheritance diagram for EventListener:

Public Member Functions

 EventListener ()
 Construct a new EventListener. More...
 
virtual ~EventListener ()
 Destructor. More...
 
virtual void onEvent (EventId aEventId, uint32 aEventData, void *aEventDataPtr, BOOL handleNow)=0
 Callback for when an event is posted. More...
 

Detailed Description

Base class for objects that take action in response to an Event being posted.

Abstract base class for objects that need to be notified of Event posting. An EventListener registers itself with the event system, and onEvent() is called when an event is posted.

Definition at line 24 of file EventListener.h.

Constructor & Destructor Documentation

EventListener::EventListener ( )

Construct a new EventListener.

Automatically registers this object with the Event manager.

Definition at line 19 of file EventListener.cpp.

References Event::addListener().

EventListener::~EventListener ( )
virtual

Destructor.

Automatically unregisters this object from the Event manager.

Definition at line 29 of file EventListener.cpp.

References Event::removeListener().

Member Function Documentation

virtual void EventListener::onEvent ( EventId  aEventId,
uint32  aEventData,
void *  aEventDataPtr,
BOOL  handleNow 
)
pure virtual

Callback for when an event is posted.

This function is called when any event has occurred.

Parameters
aEventIdThe Event ID.
aEventDataAn integer; meaning is event-specific.
aEventDataPtrA pointer; meaning is event-specific.
handleNowA boolean to determine if the event is queued or processed immediately

Implemented in CWndEventListener.


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