kaos.notification
Class KaosEnforcerAgent
java.lang.Object
kaos.notification.KaosAgent
kaos.notification.KaosEnforcerAgent
- All Implemented Interfaces:
- Enforcer, TriggerConditionListener
- Direct Known Subclasses:
- NotifyAgent
public class KaosEnforcerAgent
- extends KaosAgent
- implements Enforcer, TriggerConditionListener
Fields inherited from class kaos.notification.KaosAgent |
_ads, _agentDesc, _agentName, _agentNickname, _ans, _domainName, _guard, _kadsp, _kaosEnabled, _lctr, _logger, _msgTransport, _mts, _sr, COABSGRID_TRANSPORT, CORBA_TRANSPORT, TCP_TRANSPORT, TRANSPORT_PROPERTY_KEY |
Methods inherited from class kaos.notification.KaosAgent |
assertFalse, assertTrue, equals, getAgentDescription, getDirectoryService, getDomainName, hashCode, logMessage, logMessage, main, printTransportMessage, receiveMessage, registerWithKaos, sendMessageTo, start |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
_controlledActions
protected java.util.Vector _controlledActions
_policyTriggerActions
protected java.util.Vector _policyTriggerActions
KaosEnforcerAgent
public KaosEnforcerAgent()
initialize
public void initialize(java.lang.String domainName,
java.lang.String agentNickname,
java.lang.String parentDomainName)
throws java.lang.Exception
- Overrides:
initialize
in class KaosAgent
- Throws:
java.lang.Exception
removeAgent
protected void removeAgent()
- Overrides:
removeAgent
in class KaosAgent
getName
public java.lang.String getName()
- Called by the guard to get the enforcer's name
- Specified by:
getName
in interface Enforcer
- Returns:
- String Represents the enforcer name.
getControlledActionClasses
public java.util.Vector getControlledActionClasses()
- Called by the guard to determine what action classes this enforcer is interested in
- Specified by:
getControlledActionClasses
in interface Enforcer
- Returns:
- Vector Contains strings representing ontology originated names of Action classes.
- See Also:
Enforcer.getControlledActionClasses()
addEnforcedAction
public void addEnforcedAction(java.lang.String actionClassDaml)
updateTriggerCondition
public void updateTriggerCondition(BasicActionDescription triggerCondition)
- Description copied from interface:
TriggerConditionListener
- This method is called by Guard upon receiving an obligation policy containing the specified triggerACD.
The listener will now start monitoring agent actions in order to detect the occurrence of the trigger condition.
- Specified by:
updateTriggerCondition
in interface TriggerConditionListener
- Parameters:
triggerCondition
- BasicActionDescription describes the trigger condition the listener has registered for.
checkObligations
public boolean checkObligations(ActionInstanceDescription aid)
- This method checks whether any obligation policies are triggered by the aid
- Parameters:
aid
- ActionInstanceDescription to check obligations about
- Returns:
- Vector Vector of obligation AIDs