R
- the result typepublic abstract class AbstractRestAction<R> extends Object implements RestAction<R>
RestAction
to inheritors. This is used by GWTP code-generator to create
the actions defined by the services.Modifier | Constructor and Description |
---|---|
protected |
AbstractRestAction() |
protected |
AbstractRestAction(HttpMethod httpMethod,
String rawServicePath,
String defaultDateFormat) |
Modifier and Type | Method and Description |
---|---|
protected void |
addFormParam(String name,
Date date) |
protected void |
addFormParam(String name,
Date date,
String pattern) |
protected void |
addFormParam(String name,
Object value) |
protected void |
addHeaderParam(String name,
Date date) |
protected void |
addHeaderParam(String name,
Date date,
String pattern) |
protected void |
addHeaderParam(String name,
Object value) |
protected void |
addPathParam(String name,
Date date) |
protected void |
addPathParam(String name,
Date date,
String pattern) |
protected void |
addPathParam(String name,
Object value) |
protected void |
addQueryParam(String name,
Date date) |
protected void |
addQueryParam(String name,
Date date,
String pattern) |
protected void |
addQueryParam(String name,
Object value) |
protected String |
formatDate(Date date,
String pattern) |
Object |
getBodyParam() |
List<RestParameter> |
getFormParams() |
List<RestParameter> |
getHeaderParams() |
HttpMethod |
getHttpMethod() |
String |
getPath()
Returns the relative path for this action.
|
List<RestParameter> |
getPathParams() |
List<RestParameter> |
getQueryParams() |
Boolean |
hasBodyParam()
Verify if this action a body object.
|
Boolean |
hasFormParams()
Verify if this action contains FORM parameters.
|
protected void |
setBodyParam(Object value) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
isSecured
protected AbstractRestAction()
protected AbstractRestAction(HttpMethod httpMethod, String rawServicePath, String defaultDateFormat)
public HttpMethod getHttpMethod()
getHttpMethod
in interface RestAction<R>
HttpMethod
used to send this action over HTTP.public String getPath()
RestAction
RestApplicationPath
.getPath
in interface RestAction<R>
public List<RestParameter> getPathParams()
getPathParams
in interface RestAction<R>
List
of the @Path
parameters for this action.public List<RestParameter> getQueryParams()
getQueryParams
in interface RestAction<R>
List
of the @QueryParam
parameters for this action.public List<RestParameter> getFormParams()
getFormParams
in interface RestAction<R>
List
of the @FormParam
parameters for this action.
RestAction.getBodyParam()
should return null
.public List<RestParameter> getHeaderParams()
getHeaderParams
in interface RestAction<R>
List
of the @HeaderParam
parameters for this action.public Object getBodyParam()
getBodyParam
in interface RestAction<R>
RestAction.getFormParams()
should
return an empty list.public Boolean hasFormParams()
RestAction
RestAction.hasBodyParam()
should return false
.hasFormParams
in interface RestAction<R>
true
if this method contains form parameters, otherwise false
.public Boolean hasBodyParam()
RestAction
RestAction.hasFormParams()
should return false
.hasBodyParam
in interface RestAction<R>
true
if this method contains body object, otherwise false
.protected void setBodyParam(Object value)
Copyright © 2010–2014 Arcbees. All rights reserved.