org.jscience.computing.ai.agents
Class FlatBoundedEnvironment

java.lang.Object
  extended by org.jscience.computing.ai.agents.Environment
      extended by org.jscience.computing.ai.agents.DiscreteEnvironment
          extended by org.jscience.computing.ai.agents.FlatBoundedEnvironment

public class FlatBoundedEnvironment
extends DiscreteEnvironment

A class representing a flat environment.


Field Summary
 
Fields inherited from class org.jscience.computing.ai.agents.DiscreteEnvironment
MOORE_NEIGHBORHOOD, VON_NEUMANN_NEIGHBORHOOD
 
Constructor Summary
FlatBoundedEnvironment(int xDimension, int yDimension)
          Creates a new FlatBoundedEnvironment object.
 
Method Summary
 java.util.Set getContents()
          DOCUMENT ME!
 java.util.Set getContentsAt(int[] position)
          DOCUMENT ME!
 int getDimension()
          DOCUMENT ME!
 java.util.Set getNeighbors(int[] position, int method)
          DOCUMENT ME!
 double getSurface()
          DOCUMENT ME!
 double getXDimension()
          DOCUMENT ME!
 double getYDimension()
          DOCUMENT ME!
 boolean isCurvedOnItself()
          DOCUMENT ME!
 void setContentsAt(int[] position, java.util.Set contents)
          DOCUMENT ME!
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FlatBoundedEnvironment

public FlatBoundedEnvironment(int xDimension,
                              int yDimension)
Creates a new FlatBoundedEnvironment object.

Parameters:
xDimension - DOCUMENT ME!
yDimension - DOCUMENT ME!
Method Detail

getXDimension

public double getXDimension()
DOCUMENT ME!

Returns:
DOCUMENT ME!

getYDimension

public double getYDimension()
DOCUMENT ME!

Returns:
DOCUMENT ME!

getContents

public java.util.Set getContents()
DOCUMENT ME!

Specified by:
getContents in class Environment
Returns:
DOCUMENT ME!

isCurvedOnItself

public boolean isCurvedOnItself()
DOCUMENT ME!

Specified by:
isCurvedOnItself in class Environment
Returns:
DOCUMENT ME!

getContentsAt

public java.util.Set getContentsAt(int[] position)
DOCUMENT ME!

Specified by:
getContentsAt in class DiscreteEnvironment
Parameters:
position - DOCUMENT ME!
Returns:
DOCUMENT ME!
Throws:
IllegalDimensionException - DOCUMENT ME!

setContentsAt

public void setContentsAt(int[] position,
                          java.util.Set contents)
DOCUMENT ME!

Specified by:
setContentsAt in class DiscreteEnvironment
Parameters:
position - DOCUMENT ME!
contents - DOCUMENT ME!
Throws:
IllegalDimensionException - DOCUMENT ME!

getNeighbors

public java.util.Set getNeighbors(int[] position,
                                  int method)
DOCUMENT ME!

Specified by:
getNeighbors in class DiscreteEnvironment
Parameters:
position - DOCUMENT ME!
method - DOCUMENT ME!
Returns:
DOCUMENT ME!
Throws:
java.lang.IllegalArgumentException - DOCUMENT ME!
IllegalDimensionException - DOCUMENT ME!

getDimension

public int getDimension()
DOCUMENT ME!

Specified by:
getDimension in class DiscreteEnvironment
Returns:
DOCUMENT ME!

getSurface

public double getSurface()
DOCUMENT ME!

Returns:
DOCUMENT ME!