Package AEEvent :: Module TimerAlert :: Class TimerAlert
[hide private]
[frames] | no frames]

Class TimerAlert

source code

            object --+    
                     |    
Base.AccessEngineEvent --+
                         |
                        TimerAlert

Event that fires when a registered timer triggers a notification.

This class registers its name and whether it should be monitored by default in an AEMonitor using the Base.registerEventType function when this module is first imported. The AEMonitor can use this information to build its menus.

Instance Methods [hide private]
 
__init__(self, aid, tid, interval, **kwargs)
Stores important references.
source code
string
__str__(self)
Returns a human readable representation of this event including its name and interval.
source code
boolean
execute(self, tier_manager, **kwargs)
Contacts the TierManager and asks it to manage this chooser event.
source code
opaque object
getAppID(self)
Returns: Unique application ID identifying the top most container for the source of this event (i.e.
source code
integer
getTaskKey(self)
Gets the ID of the Task that should handle the timer event.
source code
dictionary
getDataForTask(self)
Fetches data out of this TimerAlert for use by a Task.TimerTask.
source code

Inherited from Base.AccessEngineEvent: getLayer, getPOR, getPriority, getTimestamp, setLayer, setPriority

Inherited from object: __delattr__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__

Instance Variables [hide private]
opaque aid
Unique identifier for the application Tier with which the timer that fired this event is associated
integer interval
Interval on which the timer is triggered
integer tid
ID of the Task that will handle the timer event

Inherited from Base.AccessEngineEvent: focused, por, priority

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, aid, tid, interval, **kwargs)
(Constructor)

source code 

Stores important references.

Parameters:
  • aid (opaque) - Unique identifier for the application Tier with which the timer that fired this event is associated
  • tid (integer) - ID of the Task that will handle the timer event
  • interval (integer) - Interval on which the timer is triggered
Overrides: Base.AccessEngineEvent.__init__

__str__(self)
(Informal representation operator)

source code 

Returns a human readable representation of this event including its name and interval.

Returns: string
Information about this event
Overrides: Base.AccessEngineEvent.__str__

execute(self, tier_manager, **kwargs)

source code 

Contacts the TierManager and asks it to manage this chooser event.

Parameters:
  • tier_manager (TierManager) - TierManager that will handle the event
  • kwargs (dictionary) - Packed references to other managers not of interest here
Returns: boolean
True to indicate the event executed properly
Overrides: Base.AccessEngineEvent.execute

getAppID(self)

source code 
Returns: opaque object
Unique application ID identifying the top most container for the source of this event (i.e. the application)
Overrides: Base.AccessEngineEvent.getAppID

getTaskKey(self)

source code 

Gets the ID of the Task that should handle the timer event. This information is used to locate the Task that should handle this event.

Returns: integer
ID of the Task that will handle the event

getDataForTask(self)

source code 

Fetches data out of this TimerAlert for use by a Task.TimerTask.

Returns: dictionary
Dictionary of parameters to be passed to a Task.TimerTask as follows:
  • interval: The interval on which the timer fires
Overrides: Base.AccessEngineEvent.getDataForTask