Package se.michaelthelin.spotify.enums
Enum Class ModelObjectType
- All Implemented Interfaces:
Serializable
,Comparable<ModelObjectType>
,java.lang.constant.Constable
An enumeration of all possible model object types.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum Constants -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptiongetType()
Get the model object type as a string.static ModelObjectType
Get theModelObjectType
associated with the given type string.static ModelObjectType
Returns the enum constant of this class with the specified name.static ModelObjectType[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
ALBUM
Album object type. -
ARTIST
Artist object type. -
AUDIO_FEATURES
Audio features object type. -
EPISODE
Episode object type. -
GENRE
Genre object type. -
PLAYLIST
Playlist object type. -
SHOW
Show object type. -
TRACK
Track object type. -
USER
User object type.
-
-
Field Details
-
type
The model object type identifier.
-
-
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 theModelObjectType
associated with the given type string.- Parameters:
type
- the model object type string- Returns:
- the corresponding
ModelObjectType
, or null if not found
-
getType
Get the model object type as a string.- Returns:
- The model object type as a string.
-