com.scalagent.scheduler.monitor.MonitorAgent Class Reference

Inherits fr.dyade.aaa.agent.Agent, and com.scalagent.scheduler.monitor.MonitorParent.

Inheritance diagram for com.scalagent.scheduler.monitor.MonitorAgent:

Inheritance graph
[legend]
Collaboration diagram for com.scalagent.scheduler.monitor.MonitorAgent:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 MonitorAgent (short to)
String toString ()
void sendTo (CommandMonitor monitor, AgentId to, IndexedCommand command) throws Exception
void childReport (Monitor child, int status) throws Exception
void react (AgentId from, Notification not) throws Exception

Protected Member Functions

void registerInMonitor (int id, AgentId source, Monitor monitor)

Package Attributes

InCommandTable incoming
OutCommandTable outgoing

Detailed Description

Agent which uses Monitors to perform its task.

This objects maintains two lists for outgoing IndexedCommands issued by internal Monitors, and for internal Monitors created to answer to incoming IndexedCommands.

See also:
Monitor

Definition at line 42 of file MonitorAgent.java.


Constructor & Destructor Documentation

com.scalagent.scheduler.monitor.MonitorAgent.MonitorAgent ( short  to  ) 

Creates an agent to be deployed remotely.

Parameters:
to agent server id where agent is to be deployed

Definition at line 53 of file MonitorAgent.java.

References com.scalagent.scheduler.monitor.MonitorAgent.incoming, and com.scalagent.scheduler.monitor.MonitorAgent.outgoing.


Member Function Documentation

String com.scalagent.scheduler.monitor.MonitorAgent.toString (  ) 

Provides a string image for this object.

Returns:
a string image for this object

Reimplemented from fr.dyade.aaa.agent.Agent.

Definition at line 64 of file MonitorAgent.java.

References com.scalagent.scheduler.monitor.MonitorAgent.incoming, and com.scalagent.scheduler.monitor.MonitorAgent.outgoing.

Referenced by com.scalagent.scheduler.monitor.MonitorAgent.react().

void com.scalagent.scheduler.monitor.MonitorAgent.sendTo ( CommandMonitor  monitor,
AgentId  to,
IndexedCommand  command 
) throws Exception

Allows a enclosed CommandMonitor object to send an IndexedCommand. Registers the object so that it can be forwarded the IndexedReport to.

Parameters:
monitor object sending the command
to agent target of command
command command to send

Implements com.scalagent.scheduler.monitor.MonitorParent.

Definition at line 80 of file MonitorAgent.java.

References com.scalagent.scheduler.monitor.OutCommandTable.addElement(), com.scalagent.scheduler.monitor.OutCommandHandle.id, and com.scalagent.scheduler.monitor.MonitorAgent.outgoing.

Referenced by com.scalagent.scheduler.monitor.MonitorAgent.childReport(), and com.scalagent.scheduler.monitor.MonitorAgent.react().

Here is the call graph for this function:

void com.scalagent.scheduler.monitor.MonitorAgent.registerInMonitor ( int  id,
AgentId  source,
Monitor  monitor 
) [protected]

Registers a Monitor object created to handle an IndexedCommand

Parameters:
id command identifier local to source agent
source command source agent
monitor monitor handling command

Definition at line 97 of file MonitorAgent.java.

References com.scalagent.scheduler.monitor.InCommandTable.addElement(), and com.scalagent.scheduler.monitor.MonitorAgent.incoming.

Here is the call graph for this function:

void com.scalagent.scheduler.monitor.MonitorAgent.childReport ( Monitor  child,
int  status 
) throws Exception

Reacts to a status change from child.

Parameters:
child child sending report
report new child status

Implements com.scalagent.scheduler.monitor.MonitorParent.

Definition at line 109 of file MonitorAgent.java.

References com.scalagent.scheduler.monitor.InCommandTable.getElement(), com.scalagent.scheduler.monitor.OutCommandTable.getElement(), com.scalagent.scheduler.monitor.InCommandHandle.id, com.scalagent.scheduler.monitor.MonitorAgent.incoming, com.scalagent.scheduler.monitor.MonitorAgent.outgoing, com.scalagent.scheduler.monitor.InCommandTable.removeElement(), com.scalagent.scheduler.monitor.OutCommandTable.removeElement(), com.scalagent.scheduler.monitor.MonitorAgent.sendTo(), and com.scalagent.scheduler.monitor.InCommandHandle.source.

Here is the call graph for this function:

void com.scalagent.scheduler.monitor.MonitorAgent.react ( AgentId  from,
Notification  not 
) throws Exception

Reacts to IndexedReport notifications corresponding to Monitor IndexedCommands.

Parameters:
from agent sending notification
not notification to react to

Reimplemented from fr.dyade.aaa.agent.Agent.

Definition at line 140 of file MonitorAgent.java.

References com.scalagent.scheduler.monitor.CommandMonitor.commandReport(), com.scalagent.scheduler.monitor.IndexedReport.getCommand(), com.scalagent.scheduler.monitor.OutCommandTable.getElement(), fr.dyade.aaa.agent.Agent.getId(), fr.dyade.aaa.agent.Agent.getName(), fr.dyade.aaa.agent.Agent.logmon, com.scalagent.scheduler.monitor.OutCommandHandle.monitor, com.scalagent.scheduler.monitor.MonitorAgent.outgoing, com.scalagent.scheduler.monitor.MonitorAgent.sendTo(), and com.scalagent.scheduler.monitor.MonitorAgent.toString().

Here is the call graph for this function:


Member Data Documentation

InCommandTable com.scalagent.scheduler.monitor.MonitorAgent.incoming [package]

incoming commands

Definition at line 44 of file MonitorAgent.java.

Referenced by com.scalagent.scheduler.monitor.MonitorAgent.childReport(), com.scalagent.scheduler.monitor.MonitorAgent.MonitorAgent(), com.scalagent.scheduler.monitor.MonitorAgent.registerInMonitor(), and com.scalagent.scheduler.monitor.MonitorAgent.toString().

OutCommandTable com.scalagent.scheduler.monitor.MonitorAgent.outgoing [package]

outgoing commands

Definition at line 46 of file MonitorAgent.java.

Referenced by com.scalagent.scheduler.monitor.MonitorAgent.childReport(), com.scalagent.scheduler.monitor.MonitorAgent.MonitorAgent(), com.scalagent.scheduler.monitor.MonitorAgent.react(), com.scalagent.scheduler.monitor.MonitorAgent.sendTo(), and com.scalagent.scheduler.monitor.MonitorAgent.toString().


The documentation for this class was generated from the following file:
Generated on Tue Sep 16 16:15:51 2008 for joram by  doxygen 1.5.0