Package es.situm.sdk.communication
Class HttpRequest.Builder
java.lang.Object
es.situm.sdk.communication.HttpRequest.Builder
- Enclosing class:
- HttpRequest
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionSet a custom body with the specified content typeSet the JSON body of the requestbuild()callback(Handler<? super InputStream> callback) Set the callback where you will be notified when the requests completes successfully or with an error.customHeaders(Map<String, String> customHeaders) Set custom headers of the requestSet the HTTP method.Set custom options.requestParams(Map<String, Object> requestParams) Set request paramsresponseDestinationFile(File file) Set the file where the response will be writenSet the relative url to send the request
-
Constructor Details
-
Builder
public Builder() -
Builder
-
-
Method Details
-
url
Set the relative url to send the request -
method
Set the HTTP method. Can be one ofHttpMethod -
bodyJson
Set the JSON body of the request -
body
Set a custom body with the specified content type -
requestParams
Set request params -
customHeaders
Set custom headers of the request -
options
Set custom options. SeeHttpOption -
responseDestinationFile
Set the file where the response will be writen- Parameters:
file-- Returns:
-
callback
Set the callback where you will be notified when the requests completes successfully or with an error. -
build
-