Enum Class CloseReason
- All Implemented Interfaces:
Serializable, Comparable<CloseReason>, Constable
Why an intent ended without an answer. Constants may be added in a 7.x minor release.
-
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionUiSession.close()was called.The player left the server; this includes a chest CANT_USE followed by a quit in the same tick.A chest was closed by the game or another plugin, or its first open/title reopen failed.The module that showed it was unloaded.The player explicitly closed a chest or chose a Dialog's cancel/exit action.Another intent was shown to the same player.ShowOptions.timeout()elapsed.No backend can show this intent to this player. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic CloseReasonReturns the enum constant of this class with the specified name.static CloseReason[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
PLAYER
The player explicitly closed a chest or chose a Dialog's cancel/exit action. -
INTERRUPTED
A chest was closed by the game or another plugin, or its first open/title reopen failed. For Dialogs: death, world change, or an uncancelled inventory opening interrupted the screen. -
DISCONNECTED
The player left the server; this includes a chest CANT_USE followed by a quit in the same tick. -
REPLACED
Another intent was shown to the same player. -
TIMED_OUT
ShowOptions.timeout()elapsed. -
CLOSED_BY_CODE
UiSession.close()was called. -
OWNER_UNLOADED
The module that showed it was unloaded. -
UNSUPPORTED
No backend can show this intent to this player.
-
-
Constructor Details
-
CloseReason
private CloseReason()
-
-
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
-