| 限定符和类型 | 类和说明 |
|---|---|
class |
BaseController |
| 限定符和类型 | 方法和说明 |
|---|---|
static boolean |
DomekeCaptchaRender.validate(Controller controller,
String inputRandomCode) |
| 限定符和类型 | 方法和说明 |
|---|---|
AutoBindRoutes |
AutoBindRoutes.addExcludeClasses(List<Class<? extends Controller>> clazzes) |
| 限定符和类型 | 方法和说明 |
|---|---|
Controller |
Invocation.getController()
Return the controller of this action.
|
| 构造器和说明 |
|---|
Invocation(Action action,
Controller controller) |
| 限定符和类型 | 方法和说明 |
|---|---|
Set<Map.Entry<String,Class<? extends Controller>>> |
Routes.getEntrySet() |
| 限定符和类型 | 方法和说明 |
|---|---|
Routes |
Routes.add(String controllerKey,
Class<? extends Controller> controllerClass)
Add url mapping to controller.
|
Routes |
Routes.add(String controllerKey,
Class<? extends Controller> controllerClass,
String viewPath)
Add route
|
| 限定符和类型 | 方法和说明 |
|---|---|
Controller |
Controller.keepModel(Class modelClass) |
Controller |
Controller.keepModel(Class modelClass,
String modelName) |
Controller |
Controller.keepPara()
Keep all parameter's value except model value
|
Controller |
Controller.keepPara(Class type,
String... names) |
Controller |
Controller.keepPara(Class type,
String name)
Convert para to special type and keep it
|
Controller |
Controller.keepPara(String... names)
Keep parameter's value names pointed, model value can not be kept
|
Controller |
Controller.removeAttr(String name)
Removes an attribute from this request
|
Controller |
Controller.removeCookie(String name)
Remove Cookie with path = "/".
|
Controller |
Controller.removeCookie(String name,
String path)
Remove Cookie.
|
Controller |
Controller.removeCookie(String name,
String path,
String domain)
Remove Cookie.
|
Controller |
Controller.removeSessionAttr(String key)
Remove Object in session.
|
Controller |
Controller.setAttr(String name,
Object value)
Stores an attribute in this request
|
Controller |
Controller.setAttrs(Map<String,Object> attrMap)
Stores attributes in this request, key of the map as attribute name and value of the map as
attribute value
|
Controller |
Controller.setCookie(javax.servlet.http.Cookie cookie)
Set Cookie to response.
|
Controller |
Controller.setCookie(String name,
String value,
int maxAgeInSeconds)
Set Cookie with path = "/".
|
Controller |
Controller.setCookie(String name,
String value,
int maxAgeInSeconds,
String path)
Set Cookie to response.
|
Controller |
Controller.setCookie(String name,
String value,
int maxAgeInSeconds,
String path,
String domain)
Set Cookie to response.
|
Controller |
Controller.setSessionAttr(String key,
Object value)
Store Object to session.
|
| 限定符和类型 | 方法和说明 |
|---|---|
Class<? extends Controller> |
Action.getControllerClass() |
| 构造器和说明 |
|---|
Action(String controllerKey,
String actionKey,
Class<? extends Controller> controllerClass,
Method method,
String methodName,
Interceptor[] interceptors,
String viewPath) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
RoutesHandler.addRoute(String regex,
Controller controller,
String method) |
| 限定符和类型 | 方法和说明 |
|---|---|
static boolean |
CaptchaRender.validate(Controller controller,
String inputRandomCode,
String randomCodeKey) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
I18nInterceptor.switchView(String locale,
Controller c)
在有些 web 系统中,页面需要国际化的文本过多,并且 css 以及 html 也因为际化而大不相同, 对于这种应用场景先直接制做多套同名称的国际化视图,并将这些视图以 locale
为子目录分类存放, 最后使用本拦截器根据 locale 动态切换视图,而不必对视图中的文本逐个进行国际化切换,省时省力。
|
| 限定符和类型 | 方法和说明 |
|---|---|
static void |
TokenManager.createToken(Controller controller,
String tokenName,
int secondsOfTimeOut)
Create Token.
|
static boolean |
TokenManager.validateToken(Controller controller,
String tokenName)
Check token to prevent resubmit.
|
| 限定符和类型 | 方法和说明 |
|---|---|
protected Controller |
Validator.getController()
Return the controller of this action.
|
| 限定符和类型 | 方法和说明 |
|---|---|
protected abstract void |
Validator.handleError(Controller c)
Handle the validate error.
|
protected abstract void |
Validator.validate(Controller c)
Use validateXxx method to validate the parameters of this action.
|
Copyright © 2015. All rights reserved.