Main Page   Class Hierarchy   Compound List   File List   Compound Members  

csEventQueue Class Reference

This class represents a general event queue. More...

#include <cseventq.h>

Inheritance diagram for csEventQueue:

iEventQueue iBase List of all members.

Public Methods

 csEventQueue (iObjectRegistry *, size_t iLength=DEF_EVENT_QUEUE_LENGTH)
 Initialize the event queue.

virtual ~csEventQueue ()
 Destroy an event queue object.

virtual void Process ()
 Process the event queue. Calls Dispatch() once for each contained event.

virtual void Dispatch (iEvent &)
 Dispatch a single event from the queue; normally called by Process().

virtual void RegisterListener (iEventHandler *, unsigned int trigger)
 Register a listener for specific events.

virtual void RemoveListener (iEventHandler *)
 Unregister a listener.

virtual void ChangeListenerTrigger (iEventHandler *, unsigned int trigger)
 Change a listener's trigger.

virtual iEventOutlet* CreateEventOutlet (iEventPlug *)
 Register an event plug and return a new outlet.

virtual iEventOutlet* GetEventOutlet ()
 Get a public event outlet for posting just an event.

virtual iEventCord* GetEventCord (int Category, int Subcategory)
 Get the event cord for a given category and subcategory.

virtual void Post (iEvent *)
 Place an event into queue.

virtual iEvent* Get ()
 Get next event from queue or NULL.

virtual void Clear ()
 Clear event queue.

virtual bool IsEmpty ()
 Query if queue is empty (@ Not thread safe!). More...


Public Attributes

 SCF_DECLARE_IBASE

Friends

class  csEventOutlet

Detailed Description

This class represents a general event queue.

See the documentation of iEventQueue for a detailed description of each method. One instance of this class is usually shared via iObjectRegistry.

The implemented event queue is limited thread-safe. There are some primitive spinlocks acquired/released in critical sections.


Member Function Documentation

bool csEventQueue::IsEmpty ( ) [inline, virtual]
 

Query if queue is empty (@ Not thread safe!).

@

Reimplemented from iEventQueue.


The documentation for this class was generated from the following file:
Generated for Crystal Space by doxygen 1.2.5 written by Dimitri van Heesch, ©1997-2000