Interface PagedListDescriptor<RequestT,​ResponseT,​ResourceT>


  • public interface PagedListDescriptor<RequestT,​ResponseT,​ResourceT>
    An interface which provides the functionality to extract data from requests and inject data into requests for the purposes of page streaming.

    This class is designed to be used by generated code.

    • Method Detail

      • emptyToken

        String emptyToken()
        Delivers the empty page token.
      • injectToken

        RequestT injectToken​(RequestT payload,
                             String token)
        Injects a page token into the request.
      • injectPageSize

        RequestT injectPageSize​(RequestT payload,
                                int pageSize)
        Injects page size setting into the request.
      • extractPageSize

        Integer extractPageSize​(RequestT payload)
        Extracts the page size setting from the request.
      • extractNextToken

        String extractNextToken​(ResponseT payload)
        Extracts the next token from the response. Returns the empty token if there are no more pages.
      • extractResources

        Iterable<ResourceT> extractResources​(ResponseT payload)
        Extracts an iterable of resources from the response.