abstract class BasicWSController extends java.lang.Object
| Modifiers | Name | Description |
|---|---|---|
protected java.lang.Object |
badRequest |
|
protected java.lang.Object |
notAuthorised |
|
protected java.lang.Object |
notFound |
|
protected java.lang.Object |
saveFailed |
|
protected java.lang.Object |
sendError |
|
protected java.lang.Object |
success |
Renders the provided Map as a JSON response with status code 200 |
| Type | Name and description |
|---|---|
static java.lang.String |
CONTENT_TYPE_JSON |
| Constructor and description |
|---|
BasicWSController
() |
| Type Params | Return Type | Name and description |
|---|---|---|
|
protected java.lang.Object |
handleWSResponse(java.util.Map resp)Renders the WS response structure (see ala.org.au.ws.service.WebService) as JSON, or sends a HTTP error if resp.status is not in the 2xx range. |
|
protected java.lang.Object |
isSuccessful(int statusCode)Returns true for HTTP status codes from 200 to 299 |
| Methods inherited from class | Name |
|---|---|
class java.lang.Object |
java.lang.Object#wait(long), java.lang.Object#wait(long, int), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |
Renders the provided Map as a JSON response with status code 200
resp - The map to render as JSON data on the responseRenders the WS response structure (see ala.org.au.ws.service.WebService) as JSON, or sends a HTTP error if resp.status is not in the 2xx range.
resp - response structure as returned by the ala.org.au.ws.service.WebService classReturns true for HTTP status codes from 200 to 299
Groovy Documentation