public interface HttpClientRequest
HttpClient
. Is designed to be a basic HTTP/1.1
request. See http://www.w3.org/Protocols/rfc2616/rfc2616-sec5.html#sec5
NB: 'HttpClientRequest' used rather than 'Request' to avoid clashes with Request
.Modifier and Type | Method and Description |
---|---|
void |
addCookie(String domain,
String field,
String value)
Add a cookie to the request.
|
void |
addHeader(String field,
String value)
Add a header field to the request.
|
void |
addQueryParameter(String field,
String value)
Add a query parameter to the request.
|
Set<HttpClientRequestCookie> |
getCookies()
Retrieve the cookies set on the request.
|
String |
getEntity()
Retrieve the entity set on the request.
|
Map<String,String> |
getHeaders()
Retrieve the headers set on the request.
|
String |
getMethod()
Retrieve the method set on the request.
|
Map<String,String> |
getQueryParameters()
Retrieve the query parameters set on the request.
|
String |
getUri()
Retrieve the URI that the request targets.
|
void |
setEntity(String entity)
Set the message entity.
|
void |
setMethod(String method)
Set the method the request will use.
|
void |
setUri(String uri)
Set the URI that the request targets.
|
void addHeader(String field, String value)
field
- The name of the header field to add.value
- The value of the header field.void addQueryParameter(String field, String value)
field
- The name of the query parameter field to add.value
- The value of the query parameter field.void addCookie(String domain, String field, String value)
field
- The name of the cookie field to add.value
- The value of the cookie field.void setMethod(String method)
method
- The method to use. See http://www.w3.org/Protocols/rfc2616/rfc2616-sec5.html#sec5.1.1void setUri(String uri)
uri
- The URI of the resource.void setEntity(String entity)
entity
- The entity.Map<String,String> getHeaders()
Map<String,String> getQueryParameters()
Set<HttpClientRequestCookie> getCookies()
String getMethod()
String getUri()
String getEntity()
Copyright © 2010-2018, ForgeRock All Rights Reserved.