EventHandling

Typically the EventScheduler holds the time and has some methods for scheduling events (e.g. scheduleNow, scheduleDelayed, scheduleAbsolute) as well as canceling events (cancel). Often the EventScheduler also holds the time. Thus the interface roughly looks as follows:

   1 class EventScheduler
   2 {
   3     void
   4     scheduleNow(Event);
   5 
   6     void
   7     scheduleDelayed(SimTime, Event);
   8 
   9     void
  10     scheduleAbsolute(SimTime, Event);
  11 
  12     void
  13     cancel(Event);
  14 
  15     SimTime
  16     now();
  17 }

However, the time need not be part of the EventScheduler. See the EventScheduler in Python sched.scheduler for a nice idea.

Fiet/BluePrints/EventHandling (last edited 2008-08-06 16:38:23 by localhost)