com.tootsville.npc
Enum DinerDiner.State

java.lang.Object
  extended by java.lang.Enum<DinerDiner.State>
      extended by com.tootsville.npc.DinerDiner.State
All Implemented Interfaces:
Serializable, Comparable<DinerDiner.State>
Enclosing class:
DinerDiner

protected static enum DinerDiner.State
extends Enum<DinerDiner.State>

The state of the diner's sequence of actions

Author:
brpocock

Enum Constant Summary
BEING_SEATED
          Following someone to be seated
EATING
          Eating their food
ENTERING
          Coming in to the restaurant
HUNGRY
          Waiting for food
LEAVING
          Leaving the restaurant
 
Method Summary
static DinerDiner.State valueOf(String name)
          Returns the enum constant of this type with the specified name.
static DinerDiner.State[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

ENTERING

public static final DinerDiner.State ENTERING
Coming in to the restaurant


BEING_SEATED

public static final DinerDiner.State BEING_SEATED
Following someone to be seated


HUNGRY

public static final DinerDiner.State HUNGRY
Waiting for food


EATING

public static final DinerDiner.State EATING
Eating their food


LEAVING

public static final DinerDiner.State LEAVING
Leaving the restaurant

Method Detail

values

public static DinerDiner.State[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (DinerDiner.State c : DinerDiner.State.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static DinerDiner.State valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
IllegalArgumentException - if this enum type has no constant with the specified name
NullPointerException - if the argument is null