Enum IPostContainer.SortOrder
java.lang.Object
java.lang.Enum<IPostContainer.SortOrder>
net.dv8tion.jda.api.entities.channel.attribute.IPostContainer.SortOrder
- All Implemented Interfaces:
Serializable
,Comparable<IPostContainer.SortOrder>
- Enclosing interface:
- IPostContainer
The order used to sort forum posts.
-
Enum Constant Summary
Enum ConstantDescriptionSort by the time the post was originally created.Sort by recent activity, including unarchive, message, reaction, and thread creation.Placeholder for possible future order modes. -
Method Summary
Modifier and TypeMethodDescriptionstatic IPostContainer.SortOrder
fromKey
(int key) TheIPostContainer.SortOrder
for the provided key.int
getKey()
The underlying value as used by Discord.static IPostContainer.SortOrder
Returns the enum constant of this type with the specified name.static IPostContainer.SortOrder[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
RECENT_ACTIVITY
Sort by recent activity, including unarchive, message, reaction, and thread creation. -
CREATION_TIME
Sort by the time the post was originally created. -
UNKNOWN
Placeholder for possible future order modes.
-
-
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
public int getKey()The underlying value as used by Discord.- Returns:
- The raw order key
-
fromKey
TheIPostContainer.SortOrder
for the provided key.- Parameters:
key
- The key to get theIPostContainer.SortOrder
for- Returns:
- The
IPostContainer.SortOrder
for the provided key, orUNKNOWN
if the key is not known
-