Class Agent

java.lang.Object
  |
  +--Agent
Direct Known Subclasses:
AgentX, AgentY, AgentZ

public abstract class Agent
extends Object

Abstract Class so that multiple Agent Types can be used. If you make an Agent extend this class


Constructor Summary
Agent()
           
 
Method Summary
abstract  Dimension getLocation()
          gets the agents current location
abstract  void move()
          Moves the agent intelligently, based upon class description
abstract  void setLocation(Dimension d)
          sets the agents current location
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Agent

public Agent()
Method Detail

move

public abstract void move()
Moves the agent intelligently, based upon class description


setLocation

public abstract void setLocation(Dimension d)
sets the agents current location

Parameters:
d - the location of the agent

getLocation

public abstract Dimension getLocation()
gets the agents current location

Returns:
Dimension the location of the agent