public class HttpRequestWithBody extends HttpRequest
body, urlhttpRequest, UTF_8| Constructor and Description |
|---|
HttpRequestWithBody(HttpMethod method,
String url) |
| Modifier and Type | Method and Description |
|---|---|
HttpRequestWithBody |
basicAuth(String username,
String password) |
RequestBodyEntity |
body(JsonNode body) |
RequestBodyEntity |
body(String body) |
MultipartBody |
field(String name,
File file) |
MultipartBody |
field(String name,
Object value) |
MultipartBody |
fields(Map<String,Object> parameters) |
HttpRequestWithBody |
header(String name,
String value) |
HttpRequestWithBody |
headers(Map<String,String> headers) |
HttpRequestWithBody |
routeParam(String name,
String value) |
getBody, getHeaders, getHttpMethod, getUrlasBinary, asBinaryAsync, asBinaryAsync, asJson, asJsonAsync, asJsonAsync, asString, asStringAsync, asStringAsyncpublic HttpRequestWithBody(HttpMethod method, String url)
public HttpRequestWithBody routeParam(String name, String value) throws UnirestException
routeParam in class HttpRequestUnirestExceptionpublic HttpRequestWithBody header(String name, String value)
header in class HttpRequestpublic HttpRequestWithBody headers(Map<String,String> headers)
headers in class HttpRequestpublic HttpRequestWithBody basicAuth(String username, String password)
basicAuth in class HttpRequestpublic MultipartBody field(String name, Object value)
public MultipartBody field(String name, File file)
public MultipartBody fields(Map<String,Object> parameters)
public RequestBodyEntity body(JsonNode body)
public RequestBodyEntity body(String body)
Copyright © 2014. All rights reserved.