Package net.dv8tion.jda.api.entities
Enum Entitlement.EntitlementType
java.lang.Object
java.lang.Enum<Entitlement.EntitlementType>
net.dv8tion.jda.api.entities.Entitlement.EntitlementType
- All Implemented Interfaces:
- Serializable,- Comparable<Entitlement.EntitlementType>
- Enclosing interface:
- Entitlement
Represents the type of this Entitlement
- 
Enum Constant SummaryEnum ConstantsEnum ConstantDescriptionEntitlement was purchased as an app subscriptionEntitlement was gifted by developerEntitlement was granted when the SKU was freeEntitlement was claimed by user for free as a Nitro SubscriberEntitlement for Discord Nitro subscriptionEntitlement was purchased by userEntitlement was purchased by a dev in application test modePlaceholder for unsupported types.Entitlement was gifted by another user
- 
Method SummaryModifier and TypeMethodDescriptionstatic Entitlement.EntitlementTypefromKey(int key) Gets the EntitlementType related to the provided key.intgetKey()The Discord defined id key for this EntitlementType.static Entitlement.EntitlementTypeReturns the enum constant of this type with the specified name.static Entitlement.EntitlementType[]values()Returns an array containing the constants of this enum type, in the order they are declared.
- 
Enum Constant Details- 
PURCHASEEntitlement was purchased by user
- 
PREMIUM_SUBSCRIPTIONEntitlement for Discord Nitro subscription
- 
DEVELOPER_GIFTEntitlement was gifted by developer
- 
TEST_MODE_PURCHASEEntitlement was purchased by a dev in application test mode
- 
FREE_PURCHASEEntitlement was granted when the SKU was free
- 
USER_GIFTEntitlement was gifted by another user
- 
PREMIUM_PURCHASEEntitlement was claimed by user for free as a Nitro Subscriber
- 
APPLICATION_SUBSCRIPTIONEntitlement was purchased as an app subscription
- 
UNKNOWNPlaceholder for unsupported types.
 
- 
- 
Method Details- 
valuesReturns 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
 
- 
valueOfReturns 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 name
- NullPointerException- if the argument is null
 
- 
getKeypublic int getKey()The Discord defined id key for this EntitlementType.- Returns:
- the id key.
 
- 
fromKeyGets the EntitlementType related to the provided key.
 If an unknown key is provided, this returnsUNKNOWN- Parameters:
- key- The Discord key referencing a EntitlementType.
- Returns:
- The EntitlementType that has the key provided, or UNKNOWNfor unknown key.
 
 
-