public interface IRestClient
Modifier and Type | Method and Description |
---|---|
void |
destroy()
destroy the connections
|
RestResponse |
doDELETE(String uri,
Properties headers)
This method will return resource according to the given URI.
|
RestResponse |
doGET(String uri,
Properties headers)
This method will return resource according to the given URI.
|
RestResponse |
doPOST(String uri,
Properties headers,
Object objectToCreate)
This method will CREATE resource according to the given URI.
|
RestResponse |
doPUT(String uri,
Properties headers,
Object objectToUpdate)
This method will UPDATE resource according to the given URI.
|
boolean |
init()
initialize the rest client instance.
|
boolean |
init(RestConfigurationInfo restConfigurationInfo)
initialize the rest client instance with a given timeout in milliseconds.
|
RestResponse doGET(String uri, Properties headers)
uri
- Full URL path to the desire resource.headers
- - list of headers in format of name and value, to be add as
part of the HTTP request.RestResponse doPOST(String uri, Properties headers, Object objectToCreate)
uri
- Full URL path to the desire resource.headers
- - list of headers in format of name and value, to be add as
part of the HTTP request.objectToCreate
- - JSON representation of the resource.RestResponse doPUT(String uri, Properties headers, Object objectToUpdate)
uri
- Full URL path to the desire resource.headers
- - list of headers in format of name and value, to be add as
part of the HTTP request.objectToUpdate
- - JSON representation of the resource.RestResponse doDELETE(String uri, Properties headers)
uri
- Full URL path to the desire resource.headers
- - list of headers in format of name and value, to be add as
part of the HTTP request.boolean init() throws Exception
Exception
boolean init(RestConfigurationInfo restConfigurationInfo)
restConfigurationInfo
- void destroy()
Copyright © 2017. All rights reserved.