Enum TimerActionResult
- java.lang.Object
-
- java.lang.Enum<TimerActionResult>
-
- com.scaleoutsoftware.digitaltwin.core.TimerActionResult
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<TimerActionResult>
,java.lang.constant.Constable
public enum TimerActionResult extends java.lang.Enum<TimerActionResult>
The result of a timer action.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description FailedInternalError
Failed to start/stop timer due to an internal error.FailedNoSuchTimer
Failed to stop the existing timer, the timer is no longer active.FailedTimerAlreadyExists
Failed to start the timer, the timer with the specified name already exists.FailedTooManyTimers
Failed to start a new timer due to reaching the limit for a number of active timers.Success
The operation completed successfully.
-
Method Summary
Modifier and Type Method Description static TimerActionResult
fromOrdinal(int val)
Convert an ordinal into aTimerActionResult
.static TimerActionResult
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static TimerActionResult[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
Success
public static final TimerActionResult Success
The operation completed successfully.
-
FailedTooManyTimers
public static final TimerActionResult FailedTooManyTimers
Failed to start a new timer due to reaching the limit for a number of active timers.
-
FailedNoSuchTimer
public static final TimerActionResult FailedNoSuchTimer
Failed to stop the existing timer, the timer is no longer active.
-
FailedTimerAlreadyExists
public static final TimerActionResult FailedTimerAlreadyExists
Failed to start the timer, the timer with the specified name already exists.
-
FailedInternalError
public static final TimerActionResult FailedInternalError
Failed to start/stop timer due to an internal error.
-
-
Method Detail
-
values
public static TimerActionResult[] values()
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static TimerActionResult 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
-
fromOrdinal
public static TimerActionResult fromOrdinal(int val)
Convert an ordinal into aTimerActionResult
. 0 =Success
, 1 =FailedTooManyTimers
, 2 =FailedNoSuchTimer
, 3 =FailedTimerAlreadyExists
, 4 =FailedInternalError
- Parameters:
val
- the ordinal value.- Returns:
- the associated
TimerActionResult
or throws an IllegalArgumentException for an unexpected ordinal value.
-
-