aima.basic
Class XYEnvironment

java.lang.Object
  extended by aima.basic.Environment
      extended by aima.basic.XYEnvironment

public class XYEnvironment
extends Environment


Field Summary
static java.lang.String LOCATION
           
 
Fields inherited from class aima.basic.Environment
agents, objects, views
 
Constructor Summary
XYEnvironment()
           
XYEnvironment(int width, int height)
           
 
Method Summary
 void addAgent(Agent a, XYLocation loc)
           
 void addObject(EnvironmentObject o, XYLocation loc)
           
 void executeAction(Agent a, java.lang.String Action)
           
 java.util.ArrayList<ObjectWithDynamicAttributes> getObjectsAt(XYLocation loc)
           
 java.util.ArrayList getObjectsNear(Agent agent, int radius)
           
 Percept getPerceptSeenBy(Agent anAgent)
           
 boolean isBlocked(XYLocation loc)
           
 void makePerimeter()
           
 void moveObject(Agent a, java.lang.String direction)
           
 void moveObjectToAbsoluteLocation(Agent a, XYLocation loc)
           
 
Methods inherited from class aima.basic.Environment
addAgent, addAgent, addObject, addObject, alreadyContains, alreadyContains, createExogenousChange, getAgents, getAllObjects, getObjects, isDone, registerView, step, step, stepUntilDone, updateViews
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOCATION

public static java.lang.String LOCATION
Constructor Detail

XYEnvironment

public XYEnvironment()

XYEnvironment

public XYEnvironment(int width,
                     int height)
Method Detail

addObject

public void addObject(EnvironmentObject o,
                      XYLocation loc)

addAgent

public void addAgent(Agent a,
                     XYLocation loc)

moveObjectToAbsoluteLocation

public void moveObjectToAbsoluteLocation(Agent a,
                                         XYLocation loc)

moveObject

public void moveObject(Agent a,
                       java.lang.String direction)

getObjectsAt

public java.util.ArrayList<ObjectWithDynamicAttributes> getObjectsAt(XYLocation loc)

getObjectsNear

public java.util.ArrayList getObjectsNear(Agent agent,
                                          int radius)

executeAction

public void executeAction(Agent a,
                          java.lang.String Action)
Specified by:
executeAction in class Environment

getPerceptSeenBy

public Percept getPerceptSeenBy(Agent anAgent)
Specified by:
getPerceptSeenBy in class Environment

isBlocked

public boolean isBlocked(XYLocation loc)

makePerimeter

public void makePerimeter()