Package se.michaelthelin.spotify.enums
Enum Class Action
- All Implemented Interfaces:
Serializable
,Comparable<Action>
,java.lang.constant.Constable
An enumeration of all possible
Action
types.- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionRepresents interrupting playback action.Represents pausing action.Represents resuming action.Represents seeking action.Represents skipping to next track action.Represents skipping to previous track action.Represents toggling repeat context action.Represents toggling repeat track action.Represents toggling shuffle action.Represents transferring playback action. -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptiongetKey()
Get theAction
key as a string.static Action
Get an Action by its key.static Action
Returns the enum constant of this class with the specified name.static Action[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
INTERRUPTING_PLAYBACK
Represents interrupting playback action. -
PAUSING
Represents pausing action. -
RESUMING
Represents resuming action. -
SEEKING
Represents seeking action. -
SKIPPING_NEXT
Represents skipping to next track action. -
SKIPPING_PREV
Represents skipping to previous track action. -
TOGGLING_REPEAT_CONTEXT
Represents toggling repeat context action. -
TOGGLING_SHUFFLE
Represents toggling shuffle action. -
TOGGLING_REPEAT_TRACK
Represents toggling repeat track action. -
TRANSFERRING_PLAYBACK
Represents transferring playback action.
-
-
Field Details
-
key
The action key string.
-
-
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
-
keyOf
Get an Action by its key.- Parameters:
key
- The action key.- Returns:
- The corresponding Action or null if not found.
-
getKey
Get theAction
key as a string.- Returns:
Action
key as string.
-