Enum ShutdownController.State
- java.lang.Object
-
- java.lang.Enum<ShutdownController.State>
-
- ch.raffael.meldioc.library.base.lifecycle.ShutdownController.State
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Comparable<ShutdownController.State>
- Enclosing interface:
- ShutdownController
public static enum ShutdownController.State extends java.lang.Enum<ShutdownController.State>
-
-
Enum Constant Summary
Enum Constants Enum Constant Description ANNOUNCEDA shutdown has been announced, shutdown preventing actions are not possible anymore.COMPLETEThe shutdown is complete, with or without errors.DORMANTNo shutdown initiated up to now.FINALIZINGonFinalizehook a are being run.INITIATEDA shutdown has been initiated, possibly waiting for shutdown preventing actions to finish.PERFORMINGonPerformhook a are being run.PREPARINGonPreparehook a are being run.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcheckStateBefore(ShutdownController.State before)voidcheckStateBeforeOrEqual(ShutdownController.State before)booleanisBefore(ShutdownController.State before)booleanisBeforeOrEqual(ShutdownController.State before)static ShutdownController.StatevalueOf(java.lang.String name)Returns the enum constant of this type with the specified name.static ShutdownController.State[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
DORMANT
public static final ShutdownController.State DORMANT
No shutdown initiated up to now.
-
ANNOUNCED
public static final ShutdownController.State ANNOUNCED
A shutdown has been announced, shutdown preventing actions are not possible anymore.
-
INITIATED
public static final ShutdownController.State INITIATED
A shutdown has been initiated, possibly waiting for shutdown preventing actions to finish. Shutdown preventing actions are not possible anymore.
-
PREPARING
public static final ShutdownController.State PREPARING
onPreparehook a are being run.
-
PERFORMING
public static final ShutdownController.State PERFORMING
onPerformhook a are being run.
-
FINALIZING
public static final ShutdownController.State FINALIZING
onFinalizehook a are being run.
-
COMPLETE
public static final ShutdownController.State COMPLETE
The shutdown is complete, with or without errors.
-
-
Method Detail
-
values
public static ShutdownController.State[] 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 (ShutdownController.State c : ShutdownController.State.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static ShutdownController.State valueOf(java.lang.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:
java.lang.IllegalArgumentException- if this enum type has no constant with the specified namejava.lang.NullPointerException- if the argument is null
-
isBefore
public boolean isBefore(ShutdownController.State before)
-
isBeforeOrEqual
public boolean isBeforeOrEqual(ShutdownController.State before)
-
checkStateBefore
public void checkStateBefore(ShutdownController.State before)
-
checkStateBeforeOrEqual
public void checkStateBeforeOrEqual(ShutdownController.State before)
-
-