nl.tudelft.goal.unreal.environment
Class SimpleTransitioningEnvironment

Package class diagram package SimpleTransitioningEnvironment
java.lang.Object
  extended by eis.EIDefaultImpl
      extended by eis.eis2java.environment.AbstractEnvironment
          extended by nl.tudelft.goal.unreal.environment.SimpleTransitioningEnvironment
All Implemented Interfaces:
eis.EnvironmentInterfaceStandard, Serializable
Direct Known Subclasses:
AbstractUnrealEnvironment

public abstract class SimpleTransitioningEnvironment
extends eis.eis2java.environment.AbstractEnvironment

Convenience implementation to simplify dealing with EIS state transitions. This environment hides all transitions from its subclasses and provides a better transition model. It guarantees that initialize, connect, pause, start and kill are be called in this order. The arrow indicates the direction, the brackets indicate these calls are optional. initalizeEnvironment() ---> connectEnvironment() ---> [pauseEnvironment [<---> startEnvironment] --->] killEnvironment() ---> initalizeEnvironment() --->

Author:
mpkorstanje
See Also:
Serialized Form

Constructor Summary
SimpleTransitioningEnvironment()
           
 
Method Summary
protected abstract  void connectEnvironment()
           
 void init(Map<String,eis.iilang.Parameter> parameters)
           
protected abstract  void initializeEnvironment(Map<String,eis.iilang.Parameter> parameters)
           
 void kill()
           
protected abstract  void killEnvironment()
           
 void pause()
          
protected abstract  void pauseEvironment()
           
 void start()
          
protected abstract  void startEnvironment()
           
 
Methods inherited from class eis.eis2java.environment.AbstractEnvironment
deleteEntity, getAllPerceptsFromEntity, getEntity, isSupportedByEntity, performEntityAction, registerEntity, registerEntity, registerEntity, registerEntity, requiredVersion
 
Methods inherited from class eis.EIDefaultImpl
addEntity, addEntity, associateEntity, attachAgentListener, attachEnvironmentListener, detachAgentListener, detachEnvironmentListener, freeAgent, freeEntity, freePair, getAgents, getAllPercepts, getAssociatedAgents, getAssociatedEntities, getEntities, getFreeEntities, getState, getType, isInitSupported, isKillSupported, isPauseSupported, isStartSupported, isStateTransitionValid, isSupportedByEnvironment, isSupportedByType, notifyAgents, notifyAgentsViaEntity, notifyDeletedEntity, notifyFreeEntity, notifyNewEntity, performAction, queryEntityProperty, queryProperty, registerAgent, reset, setState, setType, unregisterAgent
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SimpleTransitioningEnvironment

public SimpleTransitioningEnvironment()
Method Detail

connectEnvironment

protected abstract void connectEnvironment()
                                    throws eis.exceptions.ManagementException
Throws:
eis.exceptions.ManagementException

init

public final void init(Map<String,eis.iilang.Parameter> parameters)
                throws eis.exceptions.ManagementException
Specified by:
init in interface eis.EnvironmentInterfaceStandard
Overrides:
init in class eis.EIDefaultImpl
Throws:
eis.exceptions.ManagementException

initializeEnvironment

protected abstract void initializeEnvironment(Map<String,eis.iilang.Parameter> parameters)
                                       throws eis.exceptions.ManagementException
Throws:
eis.exceptions.ManagementException

kill

public final void kill()
                throws eis.exceptions.ManagementException
Specified by:
kill in interface eis.EnvironmentInterfaceStandard
Overrides:
kill in class eis.EIDefaultImpl
Throws:
eis.exceptions.ManagementException

killEnvironment

protected abstract void killEnvironment()
                                 throws eis.exceptions.ManagementException
Throws:
eis.exceptions.ManagementException

pause

public final void pause()
                 throws eis.exceptions.ManagementException

Specified by:
pause in interface eis.EnvironmentInterfaceStandard
Overrides:
pause in class eis.EIDefaultImpl
Throws:
eis.exceptions.ManagementException

pauseEvironment

protected abstract void pauseEvironment()
                                 throws eis.exceptions.ManagementException
Throws:
eis.exceptions.ManagementException

start

public final void start()
                 throws eis.exceptions.ManagementException

Specified by:
start in interface eis.EnvironmentInterfaceStandard
Overrides:
start in class eis.EIDefaultImpl
Throws:
eis.exceptions.ManagementException

startEnvironment

protected abstract void startEnvironment()
                                  throws eis.exceptions.ManagementException
Throws:
eis.exceptions.ManagementException


Copyright © 2012 AMIS research group, Faculty of Mathematics and Physics, Charles University in Prague, Czech Republic. All Rights Reserved.