public class CounterPlugin extends Object implements ActorPlugin
| Modifier and Type | Field and Description |
|---|---|
private int |
counterValue |
(package private) GNode |
gnodeToUpdate |
(package private) GraphUpdater |
myUpdater |
(package private) Thread |
myUpdaterThread |
private Timer |
timer |
| Constructor and Description |
|---|
CounterPlugin() |
| Modifier and Type | Method and Description |
|---|---|
ArrayList |
getPluginActorAttributes() |
ArrayList |
getPluginActorInputConceptList()
Assumption about input and output vectors is that inputs are numbered 1..n and outputs are numbered
n+1 ..
|
String |
getPluginActorName() |
ArrayList |
getPluginActorOutputConceptList()
Assumption about input and output vectors is that inputs are numbered 1..n and outputs are numbered
n+1 ..
|
String |
getSourceInfo() |
void |
performActorOperation(GraphUpdater gu,
ArrayList inputs,
ArrayList outputs)
Perform the actor's function.
|
private void |
performTimerAction() |
void |
stopActor()
Perform any clean-up required by the actor when it is deleted or its graph is de-activated.
|
private int counterValue
GNode gnodeToUpdate
GraphUpdater myUpdater
Thread myUpdaterThread
private Timer timer
public String getPluginActorName()
getPluginActorName in interface ActorPluginpublic ArrayList getPluginActorInputConceptList()
getPluginActorInputConceptList in interface ActorPluginpublic ArrayList getPluginActorOutputConceptList()
getPluginActorOutputConceptList in interface ActorPluginpublic ArrayList getPluginActorAttributes()
getPluginActorAttributes in interface ActorPluginGraphUpdater.GraphObjectAttributesprivate void performTimerAction()
public void performActorOperation(GraphUpdater gu, ArrayList inputs, ArrayList outputs) throws CGActorException
performActorOperation in interface ActorPlugingu - the current graph updater, in case the operation requires
further updatinginputs - ArrayList of charger.obj.Conceptoutputs - ArrayList of charger.obj.Concept, set by the operation and
usable by the caller.CGActorExceptionpublic void stopActor()
stopActor in interface ActorPluginpublic String getSourceInfo()
getSourceInfo in interface ActorPlugin