public class SagePagingServiceImpl extends java.lang.Object implements SagePagingService
Modifier and Type | Field and Description |
---|---|
private static java.lang.String |
ITEMS_PER_PAGE |
private SageoneRequestExecutor |
requestExecutor |
private ResponseDeserializer |
responseDeserializer |
private static java.lang.String |
START_INDEX |
Constructor and Description |
---|
SagePagingServiceImpl(SageoneRequestExecutor requestExecutor,
ResponseDeserializer responseDeserializer) |
Modifier and Type | Method and Description |
---|---|
<T> java.util.List<T> |
getFullResponse(HttpRequest<javax.ws.rs.core.Form> request,
GUID shopGuid,
com.fasterxml.jackson.core.type.TypeReference<SagePagedResponse<T>> type)
gets all Results from a SData paged resource.
|
private static final java.lang.String START_INDEX
private static final java.lang.String ITEMS_PER_PAGE
private SageoneRequestExecutor requestExecutor
private ResponseDeserializer responseDeserializer
@Inject public SagePagingServiceImpl(SageoneRequestExecutor requestExecutor, ResponseDeserializer responseDeserializer)
public <T> java.util.List<T> getFullResponse(HttpRequest<javax.ws.rs.core.Form> request, GUID shopGuid, com.fasterxml.jackson.core.type.TypeReference<SagePagedResponse<T>> type) throws RequestException, javax.validation.ValidationException, DeserializationException
SagePagingService
getFullResponse
in interface SagePagingService
request
- the HTTP request.type
- the type to deserializeRequestException
- if something went wrong with the requestjavax.validation.ValidationException
- if something went wrong with the validationDeserializationException
- if something went wrong with the deserialization