| Modifier | Constructor and Description |
|---|---|
protected |
AbstractPage(PageContext<RequestT,ResponseT,ResourceT> context,
ResponseT response) |
| Modifier and Type | Method and Description |
|---|---|
protected abstract PageT |
createPage(PageContext<RequestT,ResponseT,ResourceT> context,
ResponseT response) |
com.google.api.core.ApiFuture<PageT> |
createPageAsync(PageContext<RequestT,ResponseT,ResourceT> context,
com.google.api.core.ApiFuture<ResponseT> futureResponse) |
PageT |
getNextPage()
Retrieves the next Page object using the next page token, or
null if there are no more
pages. |
PageT |
getNextPage(int pageSize) |
com.google.api.core.ApiFuture<PageT> |
getNextPageAsync()
Returns a future for the Page object, retrieved using the next page token.
|
String |
getNextPageToken()
Returns the next page token from the response, or an empty string if there are no more pages.
|
int |
getPageElementCount() |
RequestT |
getRequest() |
ResponseT |
getResponse() |
Iterable<ResourceT> |
getValues()
Returns an iterable over the elements in this page.
|
boolean |
hasNextPage()
Returns true if there are more pages that can be retrieved from the API.
|
Iterable<ResourceT> |
iterateAll()
Returns an iterable that traverses all of the elements of the underlying data source.
|
protected AbstractPage(PageContext<RequestT,ResponseT,ResourceT> context, ResponseT response)
protected abstract PageT createPage(PageContext<RequestT,ResponseT,ResourceT> context, ResponseT response)
@InternalApi(value="Visible for testing") public com.google.api.core.ApiFuture<PageT> createPageAsync(PageContext<RequestT,ResponseT,ResourceT> context, com.google.api.core.ApiFuture<ResponseT> futureResponse)
public boolean hasNextPage()
PagehasNextPage in interface Page<ResourceT>public String getNextPageToken()
PagegetNextPageToken in interface Page<ResourceT>public PageT getNextPage()
Pagenull if there are no more
pages. The hasNextPage() method can be used to check if a Page object is available.getNextPage in interface Page<ResourceT>public PageT getNextPage(int pageSize)
public com.google.api.core.ApiFuture<PageT> getNextPageAsync()
AsyncPagegetNextPageAsync in interface AsyncPage<ResourceT>public Iterable<ResourceT> iterateAll()
PageiterateAll in interface Page<ResourceT>public Iterable<ResourceT> getValues()
Pagepublic ResponseT getResponse()
public RequestT getRequest()
public int getPageElementCount()