de.uni_paderborn.robots.robot.group10
Class ExitStrategy

java.lang.Object
  |
  +--de.uni_paderborn.robots.robot.group10.AbstractStrategy
        |
        +--de.uni_paderborn.robots.robot.group10.ExitStrategy

public class ExitStrategy
extends AbstractStrategy

one of the different strategy classes, the robot takes the shortest way to the exit.


Field Summary
private  Map.ShortestPath shortestPath
          This field stores the shortestPath this strategy uses between the game rounds
 
Fields inherited from class de.uni_paderborn.robots.robot.group10.AbstractStrategy
cardDroppedDirection, currentRobot, EXCHANGED_CARD, IDLE, lastAction, map, MOVED_AWAY, PICKED_CARD, PICKED_OLD_CARD_AGAIN, pickedCard, random, TURNED_BACK_TO_OLD
 
Constructor Summary
ExitStrategy(CardFinder robot)
          constructor for this class
 
Method Summary
 AbstractRobotAction getCommand()
          getCommand method that determines the next action to do
 
Methods inherited from class de.uni_paderborn.robots.robot.group10.AbstractStrategy
dropCard, findFreeField, getCurrentRobot, getMap, setCurrentRobot, setMap
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

shortestPath

private Map.ShortestPath shortestPath
This field stores the shortestPath this strategy uses between the game rounds
Constructor Detail

ExitStrategy

public ExitStrategy(CardFinder robot)
constructor for this class
Parameters:
robot - a reference to the reference of the robot that uses the strategy
Method Detail

getCommand

public AbstractRobotAction getCommand()
getCommand method that determines the next action to do
Overrides:
getCommand in class AbstractStrategy
Returns:
abstractAction the action to be performed