public class PaginationMapper extends ResultSetMapper
Constructor and Description |
---|
PaginationMapper(PaginationParameters paginationParameters,
MappingResponseProcessor responseProcessor,
javax.ws.rs.core.UriBuilder uriBuilder)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
protected Result |
map(Result result,
ResultSetSchema schema)
Returns a transformed result row, or null if the row is removed.
|
ResultSet |
map(ResultSet resultSet)
Cuts the result set down to just the page requested.
|
protected ResultSetSchema |
map(ResultSetSchema schema)
Returns a transformed schema.
|
equals, hashCode
public PaginationMapper(PaginationParameters paginationParameters, MappingResponseProcessor responseProcessor, javax.ws.rs.core.UriBuilder uriBuilder)
paginationParameters
- The parameters needed for paginationresponseProcessor
- The API response to which we can add the header links.uriBuilder
- The builder for creating the pagination links.public ResultSet map(ResultSet resultSet)
map
in class ResultSetMapper
resultSet
- The result set to be cut down.protected Result map(Result result, ResultSetSchema schema)
ResultSetMapper
map
in class ResultSetMapper
result
- The result row being transformedschema
- The schema for that resultprotected ResultSetSchema map(ResultSetSchema schema)
ResultSetMapper
map
in class ResultSetMapper
schema
- The schema being mappedCopyright © 2016–2018 Yahoo! Inc.. All rights reserved.