public class BaseController extends Object
| 构造器和说明 |
|---|
BaseController() |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
execute()
自动映射Handler时默认执行的方法
|
protected CodeMsg |
isTrue(boolean bool)
bool == true return SUC, 否则 return FAIL
|
protected CodeMsg |
isTrue(boolean bool,
String failMsg,
Object... failMsgArgs)
bool == true return SUC, 否则 return FAIL
返回FAIL时并设置提示信息 |
protected CodeMsg |
isTrueNone(boolean bool)
bool == true return NONE, 否则 return FAIL
|
protected CodeMsg |
isTrueNone(boolean bool,
String failMsg,
Object... failMsgArgs)
bool == true return NONE, 否则 return FAIL
返回FAIL时并设置提示信息 |
protected CodeMsg |
none()
return NONE
|
protected CodeMsg |
none(Object data)
return NONE,并设置data
|
protected <T> T |
obtainParam(javax.servlet.http.HttpServletRequest request,
String name,
Class<T> clazz)
从request中获取对应的参数
|
protected final Logger log
protected CodeMsg isTrue(boolean bool)
bool - protected CodeMsg isTrue(boolean bool, String failMsg, Object... failMsgArgs)
bool - protected CodeMsg isTrueNone(boolean bool)
bool - protected CodeMsg isTrueNone(boolean bool, String failMsg, Object... failMsgArgs)
bool - protected CodeMsg none()
Copyright © 2017. All rights reserved.