TimeEvent Struct Reference

A timed event that should be managed by a Timer object. More...

#include <timer.hpp>

Collaboration diagram for TimeEvent:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 TimeEvent (TimerCallback callback, void *param, double speed, int lifetime=1, bool autofree=false)
 Construct a new TimeEvent object.
 ~TimeEvent ()
 Unregister the object from it's owning Timer object if it has one.

Public Attributes

Timermanager
 Pointer to the Timer object that owns it Set once it has been passed to Timer::Register.
TimerCallback callback
 Function that is called each tick of the timer.
void * param
 Parameter that's passed to the callback function.
double speed
 Time between ticks in seconds.
double lasttime
 Time that the event last "ticked".
int lifetime
 Number of ticks before the Timer will stop calling it.
bool autofree
 Whether the owning Timer object should delete the TimeEvent object when it expires.


Detailed Description

A timed event that should be managed by a Timer object.

Constructor & Destructor Documentation

TimeEvent::TimeEvent ( TimerCallback  callback,
void *  param,
double  speed,
int  lifetime = 1,
bool  autofree = false 
)

Construct a new TimeEvent object.

TimeEvent::~TimeEvent (  ) 

Unregister the object from it's owning Timer object if it has one.


Member Data Documentation

Pointer to the Timer object that owns it Set once it has been passed to Timer::Register.

Function that is called each tick of the timer.

Parameter that's passed to the callback function.

Time between ticks in seconds.

Time that the event last "ticked".

Number of ticks before the Timer will stop calling it.

Whether the owning Timer object should delete the TimeEvent object when it expires.


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

Generated on Sun Apr 5 20:28:26 2009 for EOServ by  doxygen 1.5.7.1