Enum Class SchedulerState
- All Implemented Interfaces:
Serializable, Comparable<SchedulerState>, Constable
Scheduling state of a machine (ARCHITECTURE.md ยง17.1). Only
ACTIVE machines tick; the
others wait for one of their wake reasons.-
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionTicks every game tick.Output full or a dependency missing; wakes when something leaves its storages.Never ticks (placeholder, or disabled by configuration or errors).Sleeps until a known game tick.Nothing to do until any signal.Needs input; wakes when its storages receive something. -
Method Summary
Modifier and TypeMethodDescriptionstatic SchedulerStateReturns the enum constant of this class with the specified name.static SchedulerState[]values()Returns an array containing the constants of this enum class, in the order they are declared.booleanwakesOn(WakeReason reason)
-
Enum Constant Details
-
ACTIVE
Ticks every game tick. -
SCHEDULED
Sleeps until a known game tick. -
WAITING
Needs input; wakes when its storages receive something. -
BLOCKED
Output full or a dependency missing; wakes when something leaves its storages. -
SLEEPING
Nothing to do until any signal. -
DISABLED
Never ticks (placeholder, or disabled by configuration or errors).
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified nameNullPointerException- if the argument is null
-
wakesOn
- Returns:
- whether
reasonmakes a machine in this state active again
-