Class Move

java.lang.Object
  extended by Move

public class Move
extends java.lang.Object

An object representation of a move.

Author:

Field Summary
 Player thePlayer
          The player that this move is intended for.
 
Constructor Summary
Move(Player player, int startLoc, int endLoc)
          Create a move with the starting location and ending location passed in as paremeters.
 
Method Summary
 int endLocation()
          Return the ending location of this move.
 Player getPlayer()
          Return the player who made this move
 int startLocation()
          Return the starting location of this move.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

thePlayer

public Player thePlayer
The player that this move is intended for.

Constructor Detail

Move

public Move(Player player,
            int startLoc,
            int endLoc)
Create a move with the starting location and ending location passed in as paremeters.

Parameters:
startLoc - The starting point of the move
endLoc - The ending point of the move
Method Detail

getPlayer

public Player getPlayer()
Return the player who made this move

Returns:
the player who made this move

startLocation

public int startLocation()
Return the starting location of this move.

Returns:
The starting point of the move.

endLocation

public int endLocation()
Return the ending location of this move.

Returns:
The ending point of this location.