public class DefaultKeyboardSensor extends AbstractSensor
IParticipant.State
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
ACTUATOR_PARAM |
static java.lang.String |
DEVICE_MAP |
static java.lang.String |
DURATION_EQUATION |
Constructor and Description |
---|
DefaultKeyboardSensor() |
Modifier and Type | Method and Description |
---|---|
protected void |
agentAdded(IAgentObject agent)
when we detect a new agent, queue up a request to add the muscles and
devices for the hand, keyboard and mouse
|
void |
configure(java.util.Map<java.lang.String,java.lang.String> options)
configure the participant.
|
java.lang.String |
getName() |
void |
initialize()
called in response to a command from Reality to get everything ready to
run.
|
void |
resume()
resume a suspended participant and return state to started.
|
void |
start()
called to actually start this participant
|
void |
stop()
called when this participant needs to stop
|
void |
suspend()
suspend the participant if it is started.
|
agentRemoved, agentUpdated, connect, createAfferentObjectManager, createAgentObjectManager, createEfferentObjectManager, createRealObjectManager, createSensor, disconnect, getAddressingInformation, getAfferentObjectManager, getCredentials, getEfferentObjectManager, getInterfacedAgents, getRealObjectManager, isInterfacedAgent, setCredentials, setIdentifier, shouldInterface, shutdown
addClientService, addServerService, checkState, clearObjectManagers, createEfferentCommandManager, createIOExecutorService, createIOHandler, createNotificationManager, createSensorObjectManager, disconnect, getAgentObjectManager, getCentralThreadFactory, getClock, getCommonRealityIdentifier, getEfferentCommandManager, getIdentifier, getIOExecutor, getIOHandler, getIOThreadFactory, getNotificationManager, getPeriodicExecutor, getSensorObjectManager, getServerAddressInformation, getState, reset, send, setClock, setCommonRealityIdentifier, shutdown, stateMatches, waitForState, waitForState
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
disconnect, getAgentObjectManager, getClock, getEfferentCommandManager, getNotificationManager, getSensorObjectManager, getState, reset, send, shutdown, stateMatches, waitForState, waitForState
getIdentifier
public static final java.lang.String DEVICE_MAP
public static final java.lang.String ACTUATOR_PARAM
public static final java.lang.String DURATION_EQUATION
public java.lang.String getName()
getName
in class AbstractParticipant
public void configure(java.util.Map<java.lang.String,java.lang.String> options) throws java.lang.Exception
IParticipant
configure
in interface IParticipant
configure
in class AbstractParticipant
java.lang.Exception
public void initialize() throws java.lang.Exception
AbstractParticipant
initialize
in interface IParticipant
initialize
in class AbstractParticipant
java.lang.Exception
public void start() throws java.lang.Exception
AbstractParticipant
start
in interface IParticipant
start
in class AbstractParticipant
java.lang.Exception
public void stop() throws java.lang.Exception
AbstractParticipant
stop
in interface IParticipant
stop
in class AbstractParticipant
java.lang.Exception
public void suspend() throws java.lang.Exception
IParticipant
suspend
in interface IParticipant
suspend
in class AbstractParticipant
java.lang.Exception
public void resume() throws java.lang.Exception
IParticipant
resume
in interface IParticipant
resume
in class AbstractParticipant
java.lang.Exception
protected void agentAdded(IAgentObject agent)
agentAdded
in class AbstractSensor
AbstractSensor.agentAdded(org.commonreality.object.IAgentObject)