hmi.elckerlyc.wait
Class WaitPlayer

java.lang.Object
  extended by hmi.elckerlyc.wait.WaitPlayer
All Implemented Interfaces:
PUExceptionCallback, Player

public class WaitPlayer
extends Object
implements PUExceptionCallback, Player


Field Summary
private  PlanPlayer planPlayer
           
private  ExceptionManager warningManager
           
 
Constructor Summary
WaitPlayer()
           
 
Method Summary
 void addExceptionListener(BMLExceptionListener ws)
           
 void addPlanUnit(WaitUnit wu)
           
 void clearAll(double time)
           
 Set<String> getBehaviours(String bmlId)
           
 double getEndTime(String behId, String bmlId)
           
 Set<String> getInvalidBehaviors()
           
 void interruptBehaviour(String behaviourId, String bmlId, double globalTime)
           
 void interruptBehaviourBlock(String bmlId, double time)
          Interrupts all behaviors in the block; that is: calls their stop and removes them from the plan
 void play(double time)
           
 void puException(PlanUnit pu, String message, double time)
           
 void removeAllExceptionListeners()
           
 void reset()
          Reset the player.
 void setBMLBlockState(String bmlId, PlanUnitState state)
           
 void setParameterValue(String behId, String bmlId, String paramId, float value)
           
 void setParameterValue(String behId, String bmlId, String paramId, String value)
           
 void shutdown()
          Clean up resources constructed with the planner (e.g. for native stuff, spawned threads, ...).
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

planPlayer

private final PlanPlayer planPlayer

warningManager

private final ExceptionManager warningManager
Constructor Detail

WaitPlayer

public WaitPlayer()
Method Detail

clearAll

public void clearAll(double time)

reset

public void reset()
Description copied from interface: Player
Reset the player.

Specified by:
reset in interface Player

getInvalidBehaviors

public Set<String> getInvalidBehaviors()

addPlanUnit

public void addPlanUnit(WaitUnit wu)

interruptBehaviour

public void interruptBehaviour(String behaviourId,
                               String bmlId,
                               double globalTime)

play

public void play(double time)

addExceptionListener

public void addExceptionListener(BMLExceptionListener ws)
Specified by:
addExceptionListener in interface Player

removeAllExceptionListeners

public void removeAllExceptionListeners()
Specified by:
removeAllExceptionListeners in interface Player

setBMLBlockState

public void setBMLBlockState(String bmlId,
                             PlanUnitState state)
Specified by:
setBMLBlockState in interface Player

getBehaviours

public Set<String> getBehaviours(String bmlId)
Specified by:
getBehaviours in interface Player

getEndTime

public double getEndTime(String behId,
                         String bmlId)
Specified by:
getEndTime in interface Player

interruptBehaviourBlock

public void interruptBehaviourBlock(String bmlId,
                                    double time)
Description copied from interface: Player
Interrupts all behaviors in the block; that is: calls their stop and removes them from the plan

Specified by:
interruptBehaviourBlock in interface Player

puException

public void puException(PlanUnit pu,
                        String message,
                        double time)
Specified by:
puException in interface PUExceptionCallback

setParameterValue

public void setParameterValue(String behId,
                              String bmlId,
                              String paramId,
                              float value)
Specified by:
setParameterValue in interface Player

setParameterValue

public void setParameterValue(String behId,
                              String bmlId,
                              String paramId,
                              String value)
Specified by:
setParameterValue in interface Player

shutdown

public void shutdown()
Description copied from interface: Player
Clean up resources constructed with the planner (e.g. for native stuff, spawned threads, ...). A planner should not be (re)used after shutting it down.

Specified by:
shutdown in interface Player