vacworld
Class Direction

java.lang.Object
  extended by vacworld.Direction

public class Direction
extends java.lang.Object

A utility class that encapsulates information about compass directions.


Field Summary
static int[] DELTA_X
          An array for determining the change in X position that would correspond to a step in the direction indexed.
static int[] DELTA_Y
          An array for determining the change in Y position that would correspond to a step in the direction indexed.
static int EAST
           
static int NORTH
           
static int SOUTH
           
static int WEST
           
 
Constructor Summary
Direction()
           
 
Method Summary
static java.lang.String toString(int direction)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DELTA_X

public static final int[] DELTA_X
An array for determining the change in X position that would correspond to a step in the direction indexed.


DELTA_Y

public static final int[] DELTA_Y
An array for determining the change in Y position that would correspond to a step in the direction indexed.


EAST

public static final int EAST
See Also:
Constant Field Values

NORTH

public static final int NORTH
See Also:
Constant Field Values

SOUTH

public static final int SOUTH
See Also:
Constant Field Values

WEST

public static final int WEST
See Also:
Constant Field Values
Constructor Detail

Direction

public Direction()
Method Detail

toString

public static java.lang.String toString(int direction)