org.commonreality.efferent
Interface IEfferentCommand

All Superinterfaces:
IIdentifiable, ISensoryObject, ISimulationObject, java.io.Serializable
All Known Subinterfaces:
ICompoundCommand
All Known Implementing Classes:
AbstractEfferentCommand, MovementCommand, PressCommand, ReleaseCommand, RotateCommand, TranslateCommand, VocalizationCommand

public interface IEfferentCommand
extends ISensoryObject, java.io.Serializable

a command that can be issued to affect some change on an IEfferentObject. It must implement a single arg constructor with IIdentifier as the identifier of the command. This is so that they can be instantiated on remote sides correctly.

Author:
harrison

Nested Class Summary
static class IEfferentCommand.ActualState
           
static class IEfferentCommand.RequestedState
           
 
Field Summary
static java.lang.String ACTUAL_STATE
           
static java.lang.String COMMAND_CLASS_NAME
           
static java.lang.String EFFERENT_ID
           
static java.lang.String ESTIMATED_DURATION
           
static java.lang.String REQUESTED_START_TIME
           
static java.lang.String REQUESTED_STATE
           
static java.lang.String RESULT
           
 
Method Summary
 IEfferentCommand.ActualState getActualState()
           
 ISensoryIdentifier getEfferentIdentifier()
          the efferent object that this command is operating on
 double getEstimatedDuration()
           
 double getRequestedStartTime()
           
 IEfferentCommand.RequestedState getRequestedState()
           
 java.lang.Object getResult()
          what happend to interrupt the command or some outcome of the command
 IEfferentCommand.ActualState waitForActualStateChange(IEfferentCommand.ActualState waitWhileState)
          will block until the state is not waitWhileState
 
Methods inherited from interface org.commonreality.object.ISensoryObject
getIdentifier
 
Methods inherited from interface org.commonreality.object.ISimulationObject
getProperties, getProperty, getPropertyMap, hasProperty
 

Field Detail

REQUESTED_STATE

static final java.lang.String REQUESTED_STATE
See Also:
Constant Field Values

ACTUAL_STATE

static final java.lang.String ACTUAL_STATE
See Also:
Constant Field Values

RESULT

static final java.lang.String RESULT
See Also:
Constant Field Values

EFFERENT_ID

static final java.lang.String EFFERENT_ID
See Also:
Constant Field Values

COMMAND_CLASS_NAME

static final java.lang.String COMMAND_CLASS_NAME
See Also:
Constant Field Values

ESTIMATED_DURATION

static final java.lang.String ESTIMATED_DURATION
See Also:
Constant Field Values

REQUESTED_START_TIME

static final java.lang.String REQUESTED_START_TIME
See Also:
Constant Field Values
Method Detail

getEfferentIdentifier

ISensoryIdentifier getEfferentIdentifier()
the efferent object that this command is operating on

Returns:

getRequestedState

IEfferentCommand.RequestedState getRequestedState()

getActualState

IEfferentCommand.ActualState getActualState()

getResult

java.lang.Object getResult()
what happend to interrupt the command or some outcome of the command

Returns:

getEstimatedDuration

double getEstimatedDuration()

getRequestedStartTime

double getRequestedStartTime()

waitForActualStateChange

IEfferentCommand.ActualState waitForActualStateChange(IEfferentCommand.ActualState waitWhileState)
                                                      throws java.lang.InterruptedException
will block until the state is not waitWhileState

Parameters:
waitWhileState -
Returns:
Throws:
java.lang.InterruptedException