public class DefaultRequestParameterHandler extends AbstractRequestParameterHandler
CURRENT_LEVEL, XML_TAG
DEFAULT_LAYER_INDEX
构造器和说明 |
---|
DefaultRequestParameterHandler() |
限定符和类型 | 方法和说明 |
---|---|
static DefaultRequestParameterHandler |
getInstance() |
java.lang.Object |
getParameterFromAttribute(javax.servlet.http.HttpServletRequest req,
java.lang.String name)
从HTTP请求的属性中获取参数
|
java.lang.Object |
getParameterFromJSONParameters(javax.servlet.http.HttpServletRequest req,
java.lang.String paraName)
post 的 __parameters__ 不会进行 url encode,因此直接获取到
get 的 __parameters__ 会进行 url encode, 因为tomcat url中不支持{}[],
因此后台要尝试进行 url decode
|
java.lang.Object |
getParameterFromRequest(javax.servlet.http.HttpServletRequest req,
java.lang.String name)
从HTTP请求中直接获取参数
|
java.lang.Object |
getParameterFromRequestInputStream(javax.servlet.http.HttpServletRequest req,
java.lang.String name)
从HTTP请求中直接获取参数
|
java.lang.Object |
getParameterFromSession(javax.servlet.http.HttpServletRequest req,
java.lang.String paraName)
从HTTP会话中获取参数
|
currentAPILevel, layerIndex
public static DefaultRequestParameterHandler getInstance()
public java.lang.Object getParameterFromRequest(javax.servlet.http.HttpServletRequest req, java.lang.String name)
RequestParameterHandler
req
- HTTP请求name
- 参数名public java.lang.Object getParameterFromAttribute(javax.servlet.http.HttpServletRequest req, java.lang.String name)
RequestParameterHandler
req
- HTTP请求name
- 参数名public java.lang.Object getParameterFromJSONParameters(javax.servlet.http.HttpServletRequest req, java.lang.String paraName)
post 的 __parameters__ 不会进行 url encode,因此直接获取到
get 的 __parameters__ 会进行 url encode, 因为tomcat url中不支持{}[], 因此后台要尝试进行 url decode
req
- http请求paraName
- 参数名public java.lang.Object getParameterFromSession(javax.servlet.http.HttpServletRequest req, java.lang.String paraName)
RequestParameterHandler
req
- HTTP请求paraName
- 参数名public java.lang.Object getParameterFromRequestInputStream(javax.servlet.http.HttpServletRequest req, java.lang.String name)
RequestParameterHandler
req
- HTTP请求name
- 参数名