public class NullPermissionChecker extends java.lang.Object implements PermissionChecker
| Constructor and Description |
|---|
NullPermissionChecker() |
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
canActivate(Permissions has,
Permissions need,
ContextManager cm)
Checks whether the calling party (those permissions are identified by
has) can set permissions of some other party to need. |
boolean |
canSee(Permissions perms,
java.lang.String context,
ContextManager cm)
Returns true if the calling party (those permissions are identified by
perms) can see context among children of its parent context because it has non-null permissions for one or
more direct/nested children of context. |
java.lang.String |
getLevel(Permissions permissions,
java.lang.String accessedContext,
java.lang.Integer accessedEntityType,
java.lang.String accessedEntity,
java.lang.String accessedEntityGroup,
ContextManager cm)
Returns the effective permission level of the calling party (those permissions are identified by
permissions) for the entity. |
java.util.Map |
getPermissionLevels()
Returns a map of all permission levels supported by the checker.
|
java.util.Map<java.lang.String,java.lang.String> |
getRolePermissionLevels(int entityType)
Returns a map of all supported permission levels for the specified entity type.
|
boolean |
has(CallerController caller,
Permissions requiredPermissions,
Context accessedContext,
EntityDefinition accessedEntityDefinition)
Returns true if
caller is allowed to access an entity those permissions are requiredPermissions. |
boolean |
isValid(java.lang.String permType)
Returns true if permission level
permissionLevel is supported by the checker. |
public java.util.Map getPermissionLevels()
PermissionCheckergetPermissionLevels in interface PermissionCheckerpublic java.util.Map<java.lang.String,java.lang.String> getRolePermissionLevels(int entityType)
PermissionCheckergetRolePermissionLevels in interface PermissionCheckerpublic boolean has(CallerController caller, Permissions requiredPermissions, Context accessedContext, EntityDefinition accessedEntityDefinition)
PermissionCheckercaller is allowed to access an entity those permissions are requiredPermissions.has in interface PermissionCheckerpublic boolean canSee(Permissions perms, java.lang.String context, ContextManager cm)
PermissionCheckerperms) can see context among children of its parent context because it has non-null permissions for one or
more direct/nested children of context.canSee in interface PermissionCheckerpublic java.lang.String getLevel(Permissions permissions, java.lang.String accessedContext, java.lang.Integer accessedEntityType, java.lang.String accessedEntity, java.lang.String accessedEntityGroup, ContextManager cm)
PermissionCheckerpermissions) for the entity.getLevel in interface PermissionCheckerpublic boolean isValid(java.lang.String permType)
PermissionCheckerpermissionLevel is supported by the checker.isValid in interface PermissionCheckerpublic java.lang.String canActivate(Permissions has, Permissions need, ContextManager cm)
PermissionCheckerhas) can set permissions of some other party to need.canActivate in interface PermissionChecker