public class HttpRequest extends Request
Constructor and Description |
---|
HttpRequest(Context context,
ServerCall httpCall)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
boolean |
abort()
Ask the connector to attempt to abort the related network connection, for
example immediately closing the socket.
|
static void |
addHeader(Request request,
java.lang.String headerName,
java.lang.String headerValue)
Deprecated.
Use
Message.getHeaders() directly instead. |
void |
flushBuffers()
Asks the underlying connector to immediately flush the network buffers.
|
java.util.Set<java.lang.String> |
getAccessControlRequestHeaders()
Returns the modifiable set of headers the client is willing to send in
future request to this resource.
|
Method |
getAccessControlRequestMethod()
Returns the method the client is willing to use in future request to this
resource.
|
java.util.List<CacheDirective> |
getCacheDirectives()
Returns the cache directives.
|
ChallengeResponse |
getChallengeResponse()
Returns the authentication response sent by a client to an origin server.
|
ClientInfo |
getClientInfo()
Returns the client-specific information.
|
Conditions |
getConditions()
Returns the condition data applying to this call.
|
Series<Cookie> |
getCookies()
Returns the cookies provided by the client.
|
Representation |
getEntity()
Returns the representation provided by the client.
|
ServerCall |
getHttpCall()
Returns the low-level HTTP call.
|
ChallengeResponse |
getProxyChallengeResponse()
Returns the authentication response sent by a client to a proxy.
|
java.util.List<Range> |
getRanges()
Returns the ranges to return from the target resource's representation.
|
java.util.List<RecipientInfo> |
getRecipientsInfo()
Returns the intermediary recipient information.
|
Reference |
getReferrerRef()
Returns the referrer reference if available.
|
java.util.List<Warning> |
getWarnings()
Returns the additional warnings information.
|
void |
setAccessControlRequestHeaders(java.util.Set<java.lang.String> accessControlRequestHeaders)
Sets the set of headers the client is willing to use in future request to
this resource.
|
void |
setAccessControlRequestMethod(Method accessControlRequestMethod)
Sets the method the client is willing to use in future request to this
resource.
|
void |
setChallengeResponse(ChallengeResponse response)
Sets the authentication response sent by a client to an origin server.
|
void |
setEntity(Representation entity)
Sets the entity representation.
|
void |
setProxyChallengeResponse(ChallengeResponse response)
Sets the authentication response sent by a client to a proxy.
|
void |
setRecipientsInfo(java.util.List<RecipientInfo> recipientsInfo)
Sets the modifiable list of intermediary recipients.
|
void |
setWarnings(java.util.List<Warning> warnings)
Sets the additional warnings information.
|
commit, getCurrent, getHostRef, getMaxForwards, getMethod, getOnResponse, getOriginalRef, getProtocol, getResourceRef, getRootRef, isAsynchronous, isConfidential, isEntityAvailable, isExpectingResponse, isLoggable, isSynchronous, setClientInfo, setConditions, setCookies, setHostRef, setHostRef, setLoggable, setMaxForwards, setMethod, setOnResponse, setOriginalRef, setProtocol, setRanges, setReferrerRef, setReferrerRef, setResourceRef, setResourceRef, setRootRef, toString
bufferEntity, getAttributes, getDate, getEntityAsText, getHeaders, getOnError, getOnSent, release, setAttributes, setCacheDirectives, setDate, setEntity, setOnError, setOnSent
public HttpRequest(Context context, ServerCall httpCall)
context
- The context of the HTTP server connector that issued the call.httpCall
- The low-level HTTP server call.@Deprecated public static void addHeader(Request request, java.lang.String headerName, java.lang.String headerValue)
Message.getHeaders()
directly instead.request
- The request to update.headerName
- The header name to add.headerValue
- The header value to add.public boolean abort()
org.restlet.Request
public void flushBuffers() throws java.io.IOException
org.restlet.Message
flushBuffers
in class Message
java.io.IOException
public java.util.Set<java.lang.String> getAccessControlRequestHeaders()
org.restlet.Request
getAccessControlRequestHeaders
in class Request
public Method getAccessControlRequestMethod()
org.restlet.Request
getAccessControlRequestMethod
in class Request
public java.util.List<CacheDirective> getCacheDirectives()
org.restlet.Message
getCacheDirectives
in class Message
public ChallengeResponse getChallengeResponse()
org.restlet.Request
getChallengeResponse
in class Request
public ClientInfo getClientInfo()
getClientInfo
in class Request
public Conditions getConditions()
getConditions
in class Request
public Series<Cookie> getCookies()
getCookies
in class Request
public Representation getEntity()
public ServerCall getHttpCall()
public ChallengeResponse getProxyChallengeResponse()
org.restlet.Request
getProxyChallengeResponse
in class Request
public java.util.List<Range> getRanges()
org.restlet.Request
public java.util.List<RecipientInfo> getRecipientsInfo()
org.restlet.Message
getRecipientsInfo
in class Message
public Reference getReferrerRef()
getReferrerRef
in class Request
public java.util.List<Warning> getWarnings()
org.restlet.Message
getWarnings
in class Message
public void setAccessControlRequestHeaders(java.util.Set<java.lang.String> accessControlRequestHeaders)
org.restlet.Request
setAccessControlRequestHeaders
in class Request
accessControlRequestHeaders
- The set of headers the client is willing to send in future
request to this resource. Useful for CORS support.public void setAccessControlRequestMethod(Method accessControlRequestMethod)
org.restlet.Request
setAccessControlRequestMethod
in class Request
accessControlRequestMethod
- The method the client is willing to send in future request to
this resource. Useful for CORS support.public void setChallengeResponse(ChallengeResponse response)
org.restlet.Request
setChallengeResponse
in class Request
response
- The authentication response sent by a client to an origin
server.public void setEntity(Representation entity)
org.restlet.Message
public void setProxyChallengeResponse(ChallengeResponse response)
org.restlet.Request
setProxyChallengeResponse
in class Request
response
- The authentication response sent by a client to a proxy.public void setRecipientsInfo(java.util.List<RecipientInfo> recipientsInfo)
org.restlet.Message
setRecipientsInfo
in class Message
recipientsInfo
- A list of intermediary recipients.public void setWarnings(java.util.List<Warning> warnings)
org.restlet.Message
setWarnings
in class Message
warnings
- The warnings.Copyright © 2005-2024 Restlet.