H - The HTTP response headersT - The type of items contained in the Pagepublic class PagedResponseBase<H,T> extends Object implements PagedResponse<T>
Page.PagedResponse| Constructor and Description |
|---|
PagedResponseBase(HttpRequest request,
int statusCode,
HttpHeaders headers,
List<T> items,
String continuationToken,
H deserializedHeaders)
Creates a new instance of the PagedResponseBase type.
|
PagedResponseBase(HttpRequest request,
int statusCode,
HttpHeaders headers,
Page<T> page,
H deserializedHeaders)
Creates a new instance of the PagedResponseBase type.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
String |
getContinuationToken()
Gets the reference to the next page.
|
H |
getDeserializedHeaders()
Get the headers from the HTTP response, transformed into the header type H.
|
IterableStream<T> |
getElements()
Gets an
IterableStream of elements in the page. |
HttpHeaders |
getHeaders()
Gets the headers from the HTTP response.
|
HttpRequest |
getRequest()
Gets the HTTP request which resulted in this response.
|
int |
getStatusCode()
Gets the HTTP response status code.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetValuepublic PagedResponseBase(HttpRequest request, int statusCode, HttpHeaders headers, Page<T> page, H deserializedHeaders)
request - The HttpRequest that was sent to the service whose response resulted in this response.statusCode - The status code from the response.headers - The headers from the response.page - The page of content returned from the service within the response.deserializedHeaders - The headers, deserialized into an instance of type H.public PagedResponseBase(HttpRequest request, int statusCode, HttpHeaders headers, List<T> items, String continuationToken, H deserializedHeaders)
request - The HttpRequest that was sent to the service whose response resulted in this response.statusCode - The status code from the response.headers - The headers from the response.items - The items returned from the service within the response.continuationToken - The continuation token returned from the service, to enable future requests to pick up
from the same place in the paged iteration.deserializedHeaders - The headers, deserialized into an instance of type H.public IterableStream<T> getElements()
IterableStream of elements in the page.getElements in interface ContinuablePage<String,T>IterableStream containing the elements in the page.public String getContinuationToken()
getContinuationToken in interface ContinuablePage<String,T>null if there isn't a next page.public int getStatusCode()
getStatusCode in interface Response<List<T>>public HttpHeaders getHeaders()
getHeaders in interface Response<List<T>>public HttpRequest getRequest()
ResponsegetRequest in interface Response<List<T>>public H getDeserializedHeaders()
public void close()
close in interface Closeableclose in interface AutoCloseableCopyright © 2020 Microsoft Corporation. All rights reserved.