#DESIGN DOCUMENT# "Canopus" design class Board: //class which provides methods that define a maze. private final static int ROW; private final static int COL; private Piece[][] board; //indicates for each location (in the maze) the walls around it boolean[][][4] walls; public static final int EAST=1, RIGHT=1; public static final int WEST=2, LEFT=2; public static final int NORTH=4, TOP=4; public static final int SOUTH=8, BOTTOM=8; //constructor public Board(int row,int col) public getRows() public getColumns() //returns the piece at the given location, returns null if there is nothing public Piece getPiece(int row, int col) //puts the piece at the given row and column public void(Piece piece, int row, int col) //removes a piece public void remove(int row, int col) abstract class Piece extends Observable: //abstract class (extends Observable) which provides methods that define a piece private int row; private int col; public //constructor public Piece() public getRow() public setRow() public getCol() public setCol() //puts this piece at the given row and column public void place(int row, int col) //moves the piece to the given location, returns true if the move is legal public boolean moveTo(int row, int col) //removes the piece from the board public void remove() //paints this piece on the board public abstract void paint(Graphic g) class Robot extends Piece: Board board; //constructor public Robot() //paints this piece on the board public void paint(Graphics g) //returns a sequence of directions to reach the closest beeper public List getPath() /* moves the piece towards the given direction, returns true if the move is legal, increments the time by one */ public boolean move(int direction) class Beeper extends Piece: private int time; Board board; //constructor public Beeper() //paints this piece on the board public void paint(Graphics g) public getTime() public setTime() //main class class BeeperHunt: /* displays the GUI, initializes the maze, the robot and the 2 beepers */ public static void main(String arg0[]) //constructor public BeeperHunt