org.cougaar.core.plugin
Class ComponentPlugin
java.lang.Object
org.cougaar.util.GenericStateModelAdapter
org.cougaar.core.blackboard.BlackboardClientComponent
org.cougaar.core.plugin.ComponentPlugin
- All Implemented Interfaces:
- BlackboardClient, org.cougaar.core.component.Component, PluginBase, org.cougaar.util.GenericStateModel
- Direct Known Subclasses:
- AbstractMobilityPlugin, AddAgentExamplePlugin, AgentControlPlugin, AgentLoadLoggerPlugin, AgentLoadRatePlugin, AgentLoadSensorPlugin, AgentLoadTracePlugin, AgentStatusRatePlugin, ConditionServiceProvider, DeletionPlugin, DemoTimeControlPlugin, MetricsServletPlugin, MoveAgentPlugin, OperatingModeServiceProvider, ParameterizedPlugin, PersistenceAdapterPlugin, PingReceiver, PingSender, PlaybookManager, PolicyInjectorPlugin, RedirectMovePlugin, RootControlPlugin, ServiceUserPlugin, ServiceUserPluginBase, SimpleRelayExample, TestABA, TestFullSnapshot, TimestampServicePlugin
public abstract class ComponentPlugin
- extends BlackboardClientComponent
- implements PluginBase
This component is a base class for standard blackboard-client
"plugins".
Create a derived class by implementing
setupSubscriptions() and execute().
Note that both "precycle()" and "cycle()" will be run by the
scheduler. This means that the scheduling order in relation to
other scheduled Components may be *random* (i.e. this
ComponentPlugin might load first but be precycled last!). In
general a Component should not make assumptions about the
load or schedule ordering.
| Fields inherited from interface org.cougaar.util.GenericStateModel |
ACTIVE, IDLE, LOADED, UNINITIALIZED, UNLOADED |
|
Method Summary |
protected abstract void |
execute()
Called every time this component is scheduled to run. |
protected org.cougaar.util.ConfigFinder |
getConfigFinder()
|
protected abstract void |
setupSubscriptions()
Called once after initialization, as a "pre-execute()". |
| Methods inherited from class org.cougaar.core.blackboard.BlackboardClientComponent |
currentTimeMillis, cycle, getAgentIdentifier, getAlarmService, getBindingSite, getBlackboardClientName, getBlackboardService, getMessageAddress, getParameter, getParameters, getServiceBroker, halt, load, precycle, requestCycle, resume, setAgentIdentificationService, setAlarmService, setBindingSite, setBlackboardService, setParameter, setSchedulerService, setServiceBroker, setSuicideService, shouldExecute, start, stop, suspend, toString, unload, wasAwakened |
| Methods inherited from class org.cougaar.util.GenericStateModelAdapter |
getModelState, initialize, transitState |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.cougaar.util.GenericStateModel |
getModelState, halt, initialize, load, resume, start, stop, suspend, unload |
ComponentPlugin
public ComponentPlugin()
setupSubscriptions
protected abstract void setupSubscriptions()
- Called once after initialization, as a "pre-execute()".
- Specified by:
setupSubscriptions in class BlackboardClientComponent
execute
protected abstract void execute()
- Called every time this component is scheduled to run.
- Specified by:
execute in class BlackboardClientComponent
getConfigFinder
protected org.cougaar.util.ConfigFinder getConfigFinder()