|
Groovy Documentation | |||||||
| FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Objectcom.ace.mws.plugins.MoabRestResponse
public class MoabRestResponse extends Object
This class is used in the IMoabRestService to represent a response from MWS. It contains fields for the response, data, and metadata methods about the response.
| Field Summary | |
|---|---|
private net.sf.json.JSON |
data
|
private HttpServletResponse |
response
|
private boolean |
success
|
| Constructor Summary | |
MoabRestResponse(HttpServletResponse response, net.sf.json.JSON data, boolean success)
Constructs a new response from MWS. |
|
| Method Summary | |
|---|---|
net.sf.json.JSON
|
getData()
The parsed JSON body data from the response. |
HttpServletResponse
|
getResponse()
The actual response object. |
boolean
|
hasError()
Returns true if an error was encountered during the request. |
boolean
|
isSuccess()
Returns if the request was successful or not. |
| Methods inherited from class Object | |
|---|---|
| wait, wait, wait, equals, toString, hashCode, getClass, notify, notifyAll |
| Field Detail |
|---|
private final net.sf.json.JSON data
private final HttpServletResponse response
private final boolean success
| Constructor Detail |
|---|
public MoabRestResponse(HttpServletResponse response, net.sf.json.JSON data, boolean success)
response - The HTTP servlet responsedata - The data as net.sf.json.JSONsuccess - Whether or not the response is a success
| Method Detail |
|---|
public net.sf.json.JSON getData()
public HttpServletResponse getResponse()
org.springframework.mock.web.MockHttpServletResponse. This
may be used to return any pertinent information from the response including
headers and content type information.
public boolean hasError()
public boolean isSuccess()
Groovy Documentation