public abstract static class HttpRequest.Builder<T extends HttpRequest.Builder<T>> extends HttpMessage.Builder<T>
Modifier and Type | Field and Description |
---|---|
protected URI |
endpoint |
protected com.google.common.collect.ImmutableList.Builder<HttpRequestFilter> |
filters |
protected String |
method |
headers, payload
Constructor and Description |
---|
HttpRequest.Builder() |
Modifier and Type | Method and Description |
---|---|
T |
addFormParam(String name,
String... values) |
T |
addFormParams(com.google.common.collect.Multimap<String,String> parameters)
Replaces the current payload with one that is a urlencoded payload including the following
parameters and any formerly set.
|
T |
addQueryParam(String name,
Iterable<String> values) |
T |
addQueryParam(String name,
String... values) |
T |
addQueryParams(com.google.common.collect.Multimap<String,String> parameters) |
HttpRequest |
build() |
T |
endpoint(String endpoint) |
T |
endpoint(URI endpoint) |
T |
filter(HttpRequestFilter filter) |
T |
filters(Iterable<HttpRequestFilter> filters) |
T |
fromHttpRequest(HttpRequest in) |
T |
method(String method) |
T |
replaceFormParam(String name,
String... values) |
T |
replaceFormParams(com.google.common.collect.Multimap<String,String> parameters)
Replaces the current payload with one that is a urlencoded payload including the following
parameters and any formerly set.
|
T |
replacePath(String path) |
T |
replaceQueryParam(String name,
Iterable<String> values) |
T |
replaceQueryParam(String name,
String... values) |
T |
replaceQueryParams(Map<String,String> parameters) |
T |
replaceQueryParams(com.google.common.collect.Multimap<String,String> parameters) |
addHeader, fromHttpMessage, headers, payload, payload, payload, payload, payload, removeHeader, replaceHeader, replaceHeaders, self
protected String method
protected URI endpoint
protected com.google.common.collect.ImmutableList.Builder<HttpRequestFilter> filters
public T method(String method)
HttpRequest.getMethod()
public T endpoint(URI endpoint)
HttpRequest.getEndpoint()
public T endpoint(String endpoint)
HttpRequest.getEndpoint()
public T addQueryParam(String name, Iterable<String> values)
HttpRequest.getEndpoint()
public T addQueryParam(String name, String... values)
HttpRequest.getEndpoint()
public T addQueryParams(com.google.common.collect.Multimap<String,String> parameters)
HttpRequest.getEndpoint()
public T replaceQueryParam(String name, Iterable<String> values)
HttpRequest.getEndpoint()
public T replaceQueryParam(String name, String... values)
HttpRequest.getEndpoint()
public T replaceQueryParams(Map<String,String> parameters)
HttpRequest.getEndpoint()
public T replaceQueryParams(com.google.common.collect.Multimap<String,String> parameters)
HttpRequest.getEndpoint()
public T replacePath(String path)
HttpRequest.getEndpoint()
public T addFormParams(com.google.common.collect.Multimap<String,String> parameters)
PayloadEnclosingImpl.getPayload()
public T replaceFormParams(com.google.common.collect.Multimap<String,String> parameters)
PayloadEnclosingImpl.getPayload()
public T filters(Iterable<HttpRequestFilter> filters)
HttpRequest.getFilters()
public T filter(HttpRequestFilter filter)
HttpRequest.getFilters()
public HttpRequest build()
build
in class HttpMessage.Builder<T extends HttpRequest.Builder<T>>
public T fromHttpRequest(HttpRequest in)
Copyright © 2009-2013 jclouds. All Rights Reserved.