public class QPageRequest extends AbstractPageRequest
Pageable
with support for QueryDSL.Constructor and Description |
---|
QPageRequest(int page,
int size)
Creates a new
QPageRequest . |
QPageRequest(int page,
int size,
com.querydsl.core.types.OrderSpecifier<?>... orderSpecifiers)
Creates a new
QPageRequest with the given OrderSpecifier s applied. |
QPageRequest(int page,
int size,
QSort sort)
Creates a new
QPageRequest with sort parameters applied. |
Modifier and Type | Method and Description |
---|---|
Pageable |
first()
Returns the
Pageable requesting the first page. |
Sort |
getSort()
Returns the sorting parameters.
|
Pageable |
next()
|
Pageable |
previous()
|
equals, getOffset, getPageNumber, getPageSize, hashCode, hasPrevious, previousOrFirst
public QPageRequest(int page, int size)
QPageRequest
. Pages are zero indexed, thus providing 0 for page
will return the first
page.page
- must not be negative.size
- must be greater or equal to 0.public QPageRequest(int page, int size, com.querydsl.core.types.OrderSpecifier<?>... orderSpecifiers)
QPageRequest
with the given OrderSpecifier
s applied.page
- must not be negative.size
- must be greater or equal to 0.orderSpecifiers
- must not be null or empty;public QPageRequest(int page, int size, QSort sort)
QPageRequest
with sort parameters applied.page
- must not be negative.size
- must be greater or equal to 0.sort
- must not be null.public Sort getSort()
Pageable
public Pageable next()
Pageable
next
in interface Pageable
next
in class AbstractPageRequest
public Pageable previous()
AbstractPageRequest
previous
in class AbstractPageRequest
Copyright © 2011–2020 Pivotal Software, Inc.. All rights reserved.