EventEvaluator.Resource
Class TimerList

java.lang.Object
  |
  +--EventEvaluator.Resource.TimerList

public class TimerList
extends java.lang.Object

Hold the list of active events whose expression are currently TRUE. The list is implemented as a double-linked list.


Constructor Summary
TimerList(Notifier nt)
          Receives a reference to the Nofier thread, responsible for notifing the occurence of events.
 
Method Summary
 void add(ActiveEvent ae, java.lang.String meid)
          Add an active event on the list.
 void generateNotifyList()
          Generate a list of all active events that occured.
 void remove(ActiveEvent ae, java.lang.String meid)
          Remove an active event from the list.
 void removeAllEid(java.lang.String eid)
          Remove all active events from the list that are holded in an specific entity.
 void removeAllMeidPid(java.lang.String meid, java.lang.String pid)
          Remove all active events from the list whose boolean expression contains an specific parameter and are holded in an specific entity.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TimerList

public TimerList(Notifier nt)
Receives a reference to the Nofier thread, responsible for notifing the occurence of events.
Parameters:
nt - notifier thread reference
Method Detail

add

public void add(ActiveEvent ae,
                java.lang.String meid)
Add an active event on the list.
Parameters:
ae - reference to the active event
meid - entity identification where the active event is taken place

remove

public void remove(ActiveEvent ae,
                   java.lang.String meid)
Remove an active event from the list.
Parameters:
ae - reference to the active event
meid - entity identification where the active event is taken place

removeAllEid

public void removeAllEid(java.lang.String eid)
Remove all active events from the list that are holded in an specific entity.
Parameters:
eid - entity identification

removeAllMeidPid

public void removeAllMeidPid(java.lang.String meid,
                             java.lang.String pid)
Remove all active events from the list whose boolean expression contains an specific parameter and are holded in an specific entity.
Parameters:
eid - entity identification
pid - parameter identification

generateNotifyList

public void generateNotifyList()
Generate a list of all active events that occured. One active event occurs when its boolean expression stays TRUE during the duration time specified on the resource event definition.

The list of active events that occured is passed to a notifier thread, responsible for notifing their occurence.