public class AuthorizeAction extends AbstractAuthorizeAction
Determine if the action is authorized for the given roles.
| Constructor and Description |
|---|
AuthorizeAction() |
| Modifier and Type | Method and Description |
|---|---|
protected java.lang.String |
getErrorMessage(ActionContext context,
ActionConfig actionConfig)
Retrieve error message from context.
|
protected boolean |
isAuthorized(ActionContext context,
java.lang.String[] roles,
ActionConfig mapping)
Determine if the action is authorized for the given roles.
|
execute, isAuthorizationRequiredexecuteprotected boolean isAuthorized(ActionContext context, java.lang.String[] roles, ActionConfig mapping) throws java.lang.Exception
AbstractAuthorizeActionDetermine if the action is authorized for the given roles.
isAuthorized in class AbstractAuthorizeActioncontext - The Context for the current requestroles - An array of valid roles for this requestmapping - The current action mappingtrue if the request is authorized, else
falseUnauthorizedActionException - If the logic determines that the request is not authorized
but does not wish to rely upon the default mechanism reporting the error.java.lang.Exception - If the action cannot be tested for authorizationprotected java.lang.String getErrorMessage(ActionContext context, ActionConfig actionConfig)
AbstractAuthorizeActionRetrieve error message from context.
getErrorMessage in class AbstractAuthorizeActioncontext - The Context for the current requestactionConfig - The current action mappingCopyright © 2000–2024 Apache Software Foundation. All rights reserved.