Class RestPageRequest
java.lang.Object
com.atlassian.confluence.rest.v2.api.model.RestPageRequest
- All Implemented Interfaces:
PageRequest
A request for a page of data. It is a page request that also wraps the
URI
of the original request, this allows navigational URIs to be built for the
next and previous pages.- Since:
- 9.0
-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionRestPageRequest
(URI requestUri, int start, int limit) protected
RestPageRequest
(URI requestUri, int start, Cursor cursor, int limit) RestPageRequest
(URI requestUri, Cursor cursor, int limit) RestPageRequest
(URI requestUri, PageRequest original) -
Method Summary
Modifier and TypeMethodDescriptioncopyWithLimits
(PageResponse<?> response) int
getLimit()
int
getStart()
-
Field Details
-
START_QPARAM
- See Also:
-
LIMIT_QPARAM
- See Also:
-
CURSOR_QPARAM
- See Also:
-
-
Constructor Details
-
RestPageRequest
- Parameters:
requestUri
- aURI
to be used to produce the self, next and previous links to the resource handling this RestPageRequeststart
- zero-based start index for the page of results (first result is 0)limit
- the number of the results to return in the page- Since:
- 9.4
-
RestPageRequest
- Parameters:
requestUri
- aURI
to be used to produce the self, next and previous links to the resource handling this RestPageRequestcursor
- the identifier which is used to skip results from a previous query when paginatinglimit
- the number of the results to return in the page- Since:
- 9.4
-
RestPageRequest
- Parameters:
requestUri
- aURI
to be used to produce the self, next and previous links to the resource handling this RestPageRequeststart
- zero-based start index for the page of results (first result is 0). This value shouldn't be used when cursor is not null.cursor
- the identifier which is used to skip results from a previous query when paginating. This value shouldn't be used when start > 0. This value must be greater than or equal to 0.limit
- the number of the results to return in the page. This value must be greater than or equal to 0.- Throws:
BadRequestException
- when start is greater than 0 and cursor is not null, or when either limit or start are less than 0.- Since:
- 9.4
-
RestPageRequest
- Parameters:
requestUri
- aURI
to be used to produce the self, next and previous links to the resource handling this RestPageRequestoriginal
- a request which supplies the start and limit fields- Since:
- 9.4
-
-
Method Details
-
copyWithLimits
-
getStart
public int getStart()- Specified by:
getStart
in interfacePageRequest
- Returns:
- zero-based start index for the page of results (first result is 0)
-
getLimit
public int getLimit()- Specified by:
getLimit
in interfacePageRequest
- Returns:
- the number of the results to return in the page
-
getCursor
- Specified by:
getCursor
in interfacePageRequest
- Returns:
- the identifier which is used to skip results from a previous query when paginating
-
getRequestUri
- Since:
- 9.4
-