net.bluebones.boggle
Class BoardChecker

java.lang.Object
  extended by net.bluebones.boggle.BoardChecker

public class BoardChecker
extends Object

Utility class that allows checking that words can be made from a given board configuration.

Version:
0.3 $Revision: 1.3 $
Author:
Thomas David Baker

Constructor Summary
BoardChecker(char[][] letters)
          Initialises a BoardChecker with the specified letters.
 
Method Summary
 boolean checkWord(String wordToCheck)
          Checks whether the specified word can be made from this board.
static void main(String[] args)
          Simple commandline test of BoardChecker.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BoardChecker

public BoardChecker(char[][] letters)
Initialises a BoardChecker with the specified letters.

Parameters:
letters - Letters to initialise the board with.
Method Detail

checkWord

public boolean checkWord(String wordToCheck)
Checks whether the specified word can be made from this board.

Parameters:
wordToCheck - Word to look for on the board.
Returns:
Whether this word is on the board (true) or not (false).

main

public static void main(String[] args)
Simple commandline test of BoardChecker.

Parameters:
args - Commandline arguments.