org.gChess
Class Queen

java.lang.Object
  extended by org.gChess.ChessPiece
      extended by org.gChess.Queen

public class Queen
extends ChessPiece


Field Summary
 
Fields inherited from class org.gChess.ChessPiece
BLACK, WHITE
 
Constructor Summary
Queen(int color, Location loc, ChessBoard cb)
           
 
Method Summary
 java.util.ArrayList<Location> getMoveLocations()
          This method DOES NOT check that all returned locations are not occupied.
 java.util.ArrayList<Location> getValidMoveLocations()
           
 
Methods inherited from class org.gChess.ChessPiece
canMove, getBoard, getColor, getImage, getLoc, loadImage, moveTo, setLoc
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Queen

public Queen(int color,
             Location loc,
             ChessBoard cb)
Method Detail

getMoveLocations

public java.util.ArrayList<Location> getMoveLocations()
Description copied from class: ChessPiece
This method DOES NOT check that all returned locations are not occupied.

Specified by:
getMoveLocations in class ChessPiece
Returns:
an ArrayList of Locations that this chess piece potentially could move to.

getValidMoveLocations

public java.util.ArrayList<Location> getValidMoveLocations()
Overrides:
getValidMoveLocations in class ChessPiece
Returns:
an ArrayList of Locations that we can move to and that are not occupied.