Class PermissionNode
java.lang.Object
ru.bgcrm.model.user.PermissionNode
Permissions tree node, allowing one or more actions.
Each action is a semicolon separated string with action class and method names.
For example
ru.bgcrm.struts.action.admin.AppAction:status.
A node can contains many actions in case of name deprecations,
or when all of them have to be handled together.
All the node actions are allowed when the node is allowed.-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic StringSelects an action's ID (class name or path)static StringactionMethod(String action) Selects action method namestatic PermissionNodegetPermissionNode(String action) Finds permission node by action.static PermissionNodegetPermissionNodeOrThrow(String action) Finds permission node by action.static List<PermissionNode> List with root permission nodes for kernel and other enabled plugins.getTitle()booleanbooleanprimaryActions(Map<String, ConfigMap> permMap) Gets map with primary actions as keys.
-
Field Details
-
ACTION_METHOD_UNSPECIFIED
- See Also:
-
-
Method Details
-
getPermissionTrees
List with root permission nodes for kernel and other enabled plugins.- Returns:
-
-
getPermissionNode
Finds permission node by action.- Parameters:
action- semicolon separated class and method names.- Returns:
-
getPermissionNodeOrThrow
public static PermissionNode getPermissionNodeOrThrow(String action) throws javassist.NotFoundException Finds permission node by action.- Parameters:
action- semicolon separated class and method names.- Returns:
- not
nullnode value. - Throws:
javassist.NotFoundException- not found node.
-
actionId
-
actionMethod
Selects action method name- Parameters:
action- primary action class and method- Returns:
- the method name or
ACTION_METHOD_UNSPECIFIED
-
getAction
- Returns:
- the primary node action, semicolon separated action class and method names.
-
getActions
-
getTitle
- Returns:
- node title.
-
getTitlePath
- Returns:
- slash separated titles path to the node.
-
getDescription
-
isAllowAll
public boolean isAllowAll() -
isNotLogging
public boolean isNotLogging() -
getParent
- Returns:
- parent node;
-
getChildren
- Returns:
- children nodes.
-