Package net.dv8tion.jda.api.entities
Enum ClientType
- All Implemented Interfaces:
Serializable
,Comparable<ClientType>
The type of client a user might be active on.
- See Also:
-
Enum Constant Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic ClientType
Resolves the provided raw API key to the enum constant.getKey()
The raw key used by the API to identify this typestatic ClientType
Returns the enum constant of this type with the specified name.static ClientType[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
DESKTOP
The official discord desktop client -
MOBILE
The official discord mobile app -
WEB
Discord from the browser (or bot) -
UNKNOWN
Placeholder for a new type that is not yet supported here
-
-
Method Details
-
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
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:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
getKey
The raw key used by the API to identify this type- Returns:
- The raw key
-
fromKey
Resolves the provided raw API key to the enum constant.- Parameters:
key
- The api key to check- Returns:
- The resolved ClientType or
UNKNOWN
-