nl.tudelft.goal.unreal.environment
Class AbstractUnrealEnvironment

Package class diagram package AbstractUnrealEnvironment
java.lang.Object
  extended by eis.EIDefaultImpl
      extended by eis.eis2java.environment.AbstractEnvironment
          extended by nl.tudelft.goal.unreal.environment.SimpleTransitioningEnvironment
              extended by nl.tudelft.goal.unreal.environment.AbstractUnrealEnvironment
All Implemented Interfaces:
cz.cuni.amis.pogamut.base.component.IComponent, eis.EnvironmentInterfaceStandard, Serializable

public abstract class AbstractUnrealEnvironment
extends SimpleTransitioningEnvironment
implements cz.cuni.amis.pogamut.base.component.IComponent

See Also:
Serialized Form

Field Summary
protected  Configuration configuration
           
protected  cz.cuni.amis.pogamut.base.utils.logging.IAgentLogger environmentLogger
           
protected  cz.cuni.amis.pogamut.base.agent.IAgentId id
           
protected  cz.cuni.amis.pogamut.base.utils.logging.LogCategory log
           
 
Constructor Summary
AbstractUnrealEnvironment()
          Constructs the Unreal Environment.
 
Method Summary
protected  void connectEnvironment()
           
protected abstract  eis.eis2java.handlers.ActionHandler createActionHandler(UT2004BotController controller)
           
protected abstract  eis.eis2java.handlers.PerceptHandler createPerceptHandler(UT2004BotController controller)
           
protected  UT2004ServerRunner<? extends IUT2004Server,? extends UT2004AgentParameters> createServerRunner()
           
 cz.cuni.amis.pogamut.base.agent.IAgentId getComponentId()
          Provides an unique identifier for this component for use by loggers.
protected abstract  Class<? extends IUT2004BotController> getControlerClass()
           
 String getName()
           
protected  void initializeEnvironment(Map<String,eis.iilang.Parameter> parameters)
           
protected  boolean isSupportedByEnvironment(eis.iilang.Action arg0)
           
protected  boolean isSupportedByType(eis.iilang.Action arg0, String arg1)
           
protected  void killEnvironment()
           
protected  void pauseEvironment()
           
protected abstract  void registerTranslators()
           
protected  void startAgent(BotParameters parameters)
           
protected  void startEnvironment()
           
protected  void startServer()
           
protected  void synchronizedDeleteEntity(String name)
          Synchronized version of AbstractEnvironment.deleteEntity.
 String toString()
          Returns a string representation of the environment based on ID of the environment.
 
Methods inherited from class nl.tudelft.goal.unreal.environment.SimpleTransitioningEnvironment
init, kill, pause, start
 
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, 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, wait, wait, wait
 

Field Detail

id

protected final cz.cuni.amis.pogamut.base.agent.IAgentId id

environmentLogger

protected final cz.cuni.amis.pogamut.base.utils.logging.IAgentLogger environmentLogger

log

protected final cz.cuni.amis.pogamut.base.utils.logging.LogCategory log

configuration

protected Configuration configuration
Constructor Detail

AbstractUnrealEnvironment

public AbstractUnrealEnvironment()
Constructs the Unreal Environment. The environment won't be ready until until is has has been initialized.

Method Detail

registerTranslators

protected abstract void registerTranslators()

getComponentId

public cz.cuni.amis.pogamut.base.agent.IAgentId getComponentId()
Provides an unique identifier for this component for use by loggers.

Specified by:
getComponentId in interface cz.cuni.amis.pogamut.base.component.IComponent

toString

public String toString()
Returns a string representation of the environment based on ID of the environment.

Overrides:
toString in class Object
Returns:
a representation of the environment.

getName

public String getName()

initializeEnvironment

protected void initializeEnvironment(Map<String,eis.iilang.Parameter> parameters)
                              throws eis.exceptions.ManagementException
Specified by:
initializeEnvironment in class SimpleTransitioningEnvironment
Throws:
eis.exceptions.ManagementException

connectEnvironment

protected void connectEnvironment()
                           throws eis.exceptions.ManagementException
Specified by:
connectEnvironment in class SimpleTransitioningEnvironment
Throws:
eis.exceptions.ManagementException

startServer

protected void startServer()
                    throws eis.exceptions.ManagementException
Throws:
eis.exceptions.ManagementException

createServerRunner

protected UT2004ServerRunner<? extends IUT2004Server,? extends UT2004AgentParameters> createServerRunner()

startAgent

protected void startAgent(BotParameters parameters)
                   throws eis.exceptions.ManagementException
Throws:
eis.exceptions.ManagementException

getControlerClass

protected abstract Class<? extends IUT2004BotController> getControlerClass()

createPerceptHandler

protected abstract eis.eis2java.handlers.PerceptHandler createPerceptHandler(UT2004BotController controller)
                                                                      throws eis.exceptions.EntityException
Throws:
eis.exceptions.EntityException

createActionHandler

protected abstract eis.eis2java.handlers.ActionHandler createActionHandler(UT2004BotController controller)
                                                                    throws eis.exceptions.EntityException
Throws:
eis.exceptions.EntityException

startEnvironment

protected void startEnvironment()
                         throws eis.exceptions.ManagementException
Specified by:
startEnvironment in class SimpleTransitioningEnvironment
Throws:
eis.exceptions.ManagementException

pauseEvironment

protected void pauseEvironment()
Specified by:
pauseEvironment in class SimpleTransitioningEnvironment

killEnvironment

protected void killEnvironment()
Specified by:
killEnvironment in class SimpleTransitioningEnvironment

synchronizedDeleteEntity

protected void synchronizedDeleteEntity(String name)
Synchronized version of AbstractEnvironment.deleteEntity. Used by AgentDownListener to removed agents that have shut down.

Parameters:
entity - to remove.

isSupportedByEnvironment

protected boolean isSupportedByEnvironment(eis.iilang.Action arg0)
Specified by:
isSupportedByEnvironment in class eis.EIDefaultImpl

isSupportedByType

protected boolean isSupportedByType(eis.iilang.Action arg0,
                                    String arg1)
Specified by:
isSupportedByType in class eis.EIDefaultImpl


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