etomica.action.activity
Interface IController

All Superinterfaces:
ActionGroup, ActivityGroup, IAction
All Known Implementing Classes:
Controller

public interface IController
extends ActivityGroup


Method Summary
 void doActionNow(IAction action)
          Pauses current activity, executes given action, then resumes current activity.
 Controller.ActionStatus getActionStatus(IAction action)
          Returns the status of an action held by the controller.
 IEventManager getEventManager()
          Returns the event manager used by the controller to notify listeners of individual actions events as well as events related to the controller itself.
 Throwable getException(IAction action)
          Returns the exception thrown by an action held by the controller.
 void reset()
          Marks all actions as pending.
 
Methods inherited from interface etomica.action.activity.ActivityGroup
getCompletedActions, getCurrentActions, getPendingActions
 
Methods inherited from interface etomica.action.ActionGroup
addAction, getAllActions, removeAction
 
Methods inherited from interface etomica.action.IAction
actionPerformed
 

Method Detail

reset

void reset()
Marks all actions as pending. Previously completed actions are put first in the new list of pending actions. The Controller must be inactive or halted before calling this method.


getActionStatus

Controller.ActionStatus getActionStatus(IAction action)
Returns the status of an action held by the controller. Returns null for actions not held by the controller.


getException

Throwable getException(IAction action)
Returns the exception thrown by an action held by the controller. Returns null if the given action did not throw an exception or is not held by the controller.


doActionNow

void doActionNow(IAction action)
Pauses current activity, executes given action, then resumes current activity. If current action is already paused, it is not resumed by this method.

Parameters:
action - Action to be performed right away; cannot be an Activity.

getEventManager

IEventManager getEventManager()
Returns the event manager used by the controller to notify listeners of individual actions events as well as events related to the controller itself.

See Also:
ControllerEvent