public static enum TrafficLight.TrafficLightColor extends Enum<TrafficLight.TrafficLightColor>
| Enum Constant and Description |
|---|
BLACK
Traffic light is not working.
|
GREEN
GTU is allowed to drive.
|
RED
GTU needs to stop.
|
YELLOW
GTU is allowed to continue if it cannot stop anymore.
|
| Modifier and Type | Method and Description |
|---|---|
static TrafficLight.TrafficLightColor |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static TrafficLight.TrafficLightColor[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final TrafficLight.TrafficLightColor RED
public static final TrafficLight.TrafficLightColor YELLOW
public static final TrafficLight.TrafficLightColor GREEN
public static final TrafficLight.TrafficLightColor BLACK
public static TrafficLight.TrafficLightColor[] values()
for (TrafficLight.TrafficLightColor c : TrafficLight.TrafficLightColor.values()) System.out.println(c);
public static TrafficLight.TrafficLightColor valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is nullCopyright © 2014–2016 Delft University of Technology. All rights reserved.