game.checkers
Class CheckerColor

java.lang.Object
  extended bygame.checkers.CheckerColor

public class CheckerColor
extends Object

CheckerColor represents the color of a checker. It is a typesafe enumeration with only two values: RED and BLACK. CheckerColors may be compared with == or equals; both methods return the same thing.


Field Summary
static CheckerColor BLACK
          Black color.
static CheckerColor RED
          Red color.
 
Method Summary
 String toString()
          Get string representation of this color.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

RED

public static final CheckerColor RED
Red color.


BLACK

public static final CheckerColor BLACK
Black color.

Method Detail

toString

public String toString()
Get string representation of this color.

Returns:
"Red" for red, "Black" for black