com.azalient.apo.enums
Enum Equipment

java.lang.Object
  extended by java.lang.Enum<Equipment>
      extended by com.azalient.apo.enums.Equipment
All Implemented Interfaces:
Serializable, Comparable<Equipment>

public enum Equipment
extends Enum<Equipment>

The Equipment defines one "column" of a signal display. The Equipment can be variable - G,Y,R meaning green yellow and red, or fixed, such as GIVE_WAY or STOP


Enum Constant Summary
A_GYR
           
GIVE_WAY
           
L_G
           
L_GY
           
L_GYR
           
L_R
           
L_Y
           
L_YR
           
NO_ENTRY
           
NO_LEFT_TURN
           
NO_RIGHT_TURN
           
NONE
           
R_G
           
R_GY
           
R_GYR
           
R_R
           
R_Y
           
R_YR
           
ROUNDELS
           
STOP
           
 
Method Summary
 boolean compatibleWith(Signal signal)
           
 int direction()
           
 boolean[] drawBulbs()
           
 boolean hasGreen()
           
 boolean hasRed()
           
 boolean hasYellow()
           
 Icon icon()
           
static Icon[] imagesC()
           
static Icon[] imagesL()
           
static Icon[] imagesR()
           
static Equipment imageToValue(Icon image)
           
static Equipment parseString(String s)
           
 boolean roundels()
           
static Equipment valueOf(String name)
          Returns the enum constant of this type with the specified name.
static Equipment[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 boolean variable()
           
 
Methods inherited from class java.lang.Enum
compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

ROUNDELS

public static final Equipment ROUNDELS

A_GYR

public static final Equipment A_GYR

L_GYR

public static final Equipment L_GYR

L_GY

public static final Equipment L_GY

L_YR

public static final Equipment L_YR

L_G

public static final Equipment L_G

L_R

public static final Equipment L_R

L_Y

public static final Equipment L_Y

R_GYR

public static final Equipment R_GYR

R_GY

public static final Equipment R_GY

R_YR

public static final Equipment R_YR

R_G

public static final Equipment R_G

R_R

public static final Equipment R_R

R_Y

public static final Equipment R_Y

GIVE_WAY

public static final Equipment GIVE_WAY

STOP

public static final Equipment STOP

NO_LEFT_TURN

public static final Equipment NO_LEFT_TURN

NO_RIGHT_TURN

public static final Equipment NO_RIGHT_TURN

NO_ENTRY

public static final Equipment NO_ENTRY

NONE

public static final Equipment NONE
Method Detail

values

public static Equipment[] 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 (Equipment c : Equipment.values())
    System.out.println(c);

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

valueOf

public static Equipment 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

drawBulbs

public boolean[] drawBulbs()

icon

public Icon icon()

roundels

public boolean roundels()

direction

public int direction()

hasGreen

public boolean hasGreen()

hasYellow

public boolean hasYellow()

hasRed

public boolean hasRed()

parseString

public static Equipment parseString(String s)

imagesL

public static Icon[] imagesL()

imagesC

public static Icon[] imagesC()

imagesR

public static Icon[] imagesR()

imageToValue

public static Equipment imageToValue(Icon image)

variable

public boolean variable()

compatibleWith

public boolean compatibleWith(Signal signal)