| java.lang.Object |
| ↳ |
org.mule.modules.jive.api.JiveClient |
Class Overview
Class that holds the WebResource and make the requests.
Summary
| Fields |
|
private
final
XmlMapper |
mapper |
Mapper to parse the data from Map to xml and viceversa |
|
private
final
WebResource |
resource |
The jersey WebResource to perform the requests |
| Public Constructors |
|
|
JiveClient(WebResource gateway)
|
| Public Methods |
|
Map<String, Object>
|
doRequest(String uri, String method, String pathParams)
|
|
String
|
doRequestAndExtractTagBetween(String uri, String method, String tagName)
Executes an operation and extract the response from the xml from the given tagName.
|
|
Map<String, Object>
|
doRequestWithPayload(String uri, String method, String payload)
Executes a request sending the payload given
|
|
[Expand]
Inherited Methods |
From class
java.lang.Object
|
Object
|
clone()
|
|
boolean
|
equals(Object arg0)
|
|
void
|
finalize()
|
|
final
Class<?>
|
getClass()
|
|
int
|
hashCode()
|
|
final
void
|
notify()
|
|
final
void
|
notifyAll()
|
|
String
|
toString()
|
|
final
void
|
wait()
|
|
final
void
|
wait(long arg0, int arg1)
|
|
final
void
|
wait(long arg0)
|
|
Constants
private
static
final
int
serverMinAcceptableStatus
The server response minimun acceptable status
Constant Value:
300
(0x0000012c)
Fields
private
final
XmlMapper
mapper
Mapper to parse the data from Map to xml and viceversa
private
final
WebResource
resource
The jersey WebResource to perform the requests
Public Constructors
public
JiveClient
(WebResource gateway)
Public Methods
public
Map<String, Object>
doRequest
(String uri, String method, String pathParams)
Parameters
| uri
| The resource uri to make the request |
| method
| The http method to use |
| pathParams
| The path params to add to the resource uri separated by ':' |
Returns
- A Map with the server response
public
String
doRequestAndExtractTagBetween
(String uri, String method, String tagName)
Executes an operation and extract the response from the xml from the given tagName.
Parameters
| uri
| The resource uri to make the request |
| method
| The http method to use |
| tagName
| The tagName that holds the answer |
public
Map<String, Object>
doRequestWithPayload
(String uri, String method, String payload)
Executes a request sending the payload given
Parameters
| uri
| The resource uri to make the request |
| method
| The http method to use |
| payload
| The payload as xml |