Package games.stendhal.server.core.rp
Enum Class DaylightPhase
- All Implemented Interfaces:
Serializable
,Comparable<DaylightPhase>
,Constable
day light phase
- Author:
- hendrik
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic DaylightPhase
current()
gets the current daylight phasegetColor()
gets the color of this daylight phaseGets the greeting namestatic void
setTestingPhase(DaylightPhase phase)
WARNING: this should only be used for testing purposes.static void
Disables testing phase.static DaylightPhase
Returns the enum constant of this class with the specified name.static DaylightPhase[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
NIGHT
during the night -
DAWN
early morning before sunrise at -
SUNRISE
the sun is rising -
DAY
during the day -
SUNSET
the sun is setting -
DUSK
early night
-
-
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
-
current
gets the current daylight phase- Returns:
- DaylightPhase
-
getColor
gets the color of this daylight phase- Returns:
- color
-
getGreetingName
Gets the greeting name- Returns:
- greeting name
-
setTestingPhase
WARNING: this should only be used for testing purposes.- Parameters:
phase
-DaylightPhase
to set for testing.
-
unsetTestingPhase
public static void unsetTestingPhase()Disables testing phase.
-