public class HttpMethodCall
extends org.restlet.engine.adapter.ClientCall
Modifier and Type | Field and Description |
---|---|
private HttpDOIClientHelper |
clientHelper
The associated HTTP client.
|
private org.apache.http.client.methods.HttpUriRequest |
httpRequest
The wrapped HTTP request.
|
private org.apache.http.HttpResponse |
httpResponse
The wrapped HTTP response.
|
private boolean |
responseHeadersAdded
Indicates if the response headers were added.
|
Constructor and Description |
---|
HttpMethodCall(HttpDOIClientHelper helper,
String method,
String requestUri,
boolean hasEntity)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
org.apache.http.client.methods.HttpUriRequest |
getHttpRequest()
Returns the HTTP request.
|
org.apache.http.HttpResponse |
getHttpResponse()
Returns the HTTP response.
|
String |
getReasonPhrase() |
WritableByteChannel |
getRequestEntityChannel()
Not used.
|
OutputStream |
getRequestEntityStream()
Not used.
|
OutputStream |
getRequestHeadStream()
Not used.
|
ReadableByteChannel |
getResponseEntityChannel(long size)
Not used.
|
InputStream |
getResponseEntityStream(long size) |
org.restlet.util.Series<org.restlet.data.Header> |
getResponseHeaders() |
String |
getServerAddress() |
int |
getStatusCode() |
org.restlet.data.Status |
sendRequest(org.restlet.Request request) |
void |
sendRequest(org.restlet.Request request,
org.restlet.Response response,
org.restlet.Uniform callback) |
getContentLength, getHelper, getLocalAddress, getResponseEntity, isClientKeepAlive, isServerKeepAlive, shouldRequestBeChunked
getClientAddress, getClientPort, getHostDomain, getHostPort, getLogger, getMethod, getProtocol, getRepresentation, getRepresentation, getRequestHeaders, getRequestUri, getServerPort, getUserPrincipal, getVersion, isBroken, isConfidential, isConnectionBroken, isKeepAlive, isRequestChunked, isResponseChunked, setClientAddress, setClientPort, setConfidential, setHostDomain, setHostPort, setMethod, setProtocol, setReasonPhrase, setRequestUri, setServerAddress, setServerPort, setStatusCode, setUserPrincipal, setVersion
private volatile HttpDOIClientHelper clientHelper
private volatile org.apache.http.client.methods.HttpUriRequest httpRequest
private volatile org.apache.http.HttpResponse httpResponse
private volatile boolean responseHeadersAdded
public HttpMethodCall(HttpDOIClientHelper helper, String method, String requestUri, boolean hasEntity) throws IOException
helper
- The parent HTTP client helper.method
- The method name.requestUri
- The request URI.hasEntity
- Indicates if the call will have an entity to send to the
server.IOException
- when an error happenspublic org.apache.http.client.methods.HttpUriRequest getHttpRequest()
public org.apache.http.HttpResponse getHttpResponse()
public String getReasonPhrase()
getReasonPhrase
in class org.restlet.engine.adapter.Call
public WritableByteChannel getRequestEntityChannel()
getRequestEntityChannel
in class org.restlet.engine.adapter.ClientCall
public OutputStream getRequestEntityStream()
getRequestEntityStream
in class org.restlet.engine.adapter.ClientCall
public OutputStream getRequestHeadStream()
getRequestHeadStream
in class org.restlet.engine.adapter.ClientCall
public ReadableByteChannel getResponseEntityChannel(long size)
getResponseEntityChannel
in class org.restlet.engine.adapter.ClientCall
public InputStream getResponseEntityStream(long size)
getResponseEntityStream
in class org.restlet.engine.adapter.ClientCall
public org.restlet.util.Series<org.restlet.data.Header> getResponseHeaders()
getResponseHeaders
in class org.restlet.engine.adapter.Call
public String getServerAddress()
getServerAddress
in class org.restlet.engine.adapter.Call
public int getStatusCode()
getStatusCode
in class org.restlet.engine.adapter.Call
public org.restlet.data.Status sendRequest(org.restlet.Request request)
sendRequest
in class org.restlet.engine.adapter.ClientCall
Copyright © 2017–2020 CNES. All rights reserved.