Enum PaginationAction.PaginationOrder
- java.lang.Object
-
- java.lang.Enum<PaginationAction.PaginationOrder>
-
- net.dv8tion.jda.api.requests.restaction.pagination.PaginationAction.PaginationOrder
-
- All Implemented Interfaces:
Serializable
,Comparable<PaginationAction.PaginationOrder>
- Enclosing interface:
- PaginationAction<T,M extends PaginationAction<T,M>>
public static enum PaginationAction.PaginationOrder extends Enum<PaginationAction.PaginationOrder>
Defines the pagination order for a pagination endpoint.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getKey()
The API query parameter keystatic PaginationAction.PaginationOrder
valueOf(String name)
Returns the enum constant of this type with the specified name.static PaginationAction.PaginationOrder[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
BACKWARD
public static final PaginationAction.PaginationOrder BACKWARD
Iterates backwards in time, listing the most recent entities first.
-
FORWARD
public static final PaginationAction.PaginationOrder FORWARD
Iterates forward in time, listing the oldest entities first.
-
-
Method Detail
-
values
public static PaginationAction.PaginationOrder[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (PaginationAction.PaginationOrder c : PaginationAction.PaginationOrder.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static PaginationAction.PaginationOrder valueOf(String name)
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
-
-