public interface AccessController
Modifier and Type | Interface and Description |
---|---|
static class |
AccessController.AccessResult
The access result when looking for a right
|
Modifier and Type | Method and Description |
---|---|
AccessController.AccessResult |
getPermission(UserIdentity user,
Set<GroupIdentity> userGroups,
String rightId,
Object object)
Gets the kind of access a user has on an object for a given right
|
Map<GroupIdentity,AccessController.AccessResult> |
getPermissionByGroup(String rightId,
Object object)
Gets the permission by group only on an object for the given right.
|
Map<String,AccessController.AccessResult> |
getPermissionByRight(UserIdentity user,
Set<GroupIdentity> userGroups,
Object object)
Gets the kind of access a user has on an object for all rights
|
Map<UserIdentity,AccessController.AccessResult> |
getPermissionByUser(String rightId,
Object object)
Gets the permission by user only on an object for the given right.
|
AccessController.AccessResult |
getPermissionForAnonymous(String rightId,
Object object)
Gets the permission for Anonymous only on an object for a given right
|
AccessController.AccessResult |
getPermissionForAnyConnectedUser(String rightId,
Object object)
Gets the permission for any connected user only on an object for a given right
|
AccessController.AccessResult |
getReadAccessPermission(UserIdentity user,
Set<GroupIdentity> userGroups,
Object object)
Gets the kind of access a user has on an object for thye read access
|
Map<GroupIdentity,AccessController.AccessResult> |
getReadAccessPermissionByGroup(Object object)
Gets the read access permission by group only on an object.
|
Map<UserIdentity,AccessController.AccessResult> |
getReadAccessPermissionByUser(Object object)
Gets the read access permission by user only on an object.
|
AccessController.AccessResult |
getReadAccessPermissionForAnonymous(Object object)
Gets the read access permission for Anonymous only on an object
|
AccessController.AccessResult |
getReadAccessPermissionForAnyConnectedUser(Object object)
Gets the read access permission for any connected user only on an object
|
boolean |
hasAnonymousAnyPermissionOnWorkspace(Set<Object> workspacesContexts,
String rightId)
Returns true if anonymous has a permission on at least one object, directly or though groups, for a given rights and if the object is attached to the given context that is /${WorkspaceName} and its conversions.
|
boolean |
hasAnonymousAnyReadAccessPermissionOnWorkspace(Set<Object> workspacesContexts)
Returns true if anonymous has a read access permission on at least one object, directly or though groups, for a given rights and if the object is attached to the given context that is /${WorkspaceName} and its conversions.
|
boolean |
hasAnyConnectedUserAnyPermissionOnWorkspace(Set<Object> workspacesContexts,
String rightId)
Returns true if any connected user has a permission on at least one object, directly or though groups, for a given rights and if the object is attached to the given context that is /${WorkspaceName} and its conversions.
|
boolean |
hasAnyConnectedUserAnyReadAccessPermissionOnWorkspace(Set<Object> workspacesContexts)
Returns true if any connected user has a read access permission on at least one object, directly or though groups, for a given rights and if the object is attached to the given context that is /${WorkspaceName} and its conversions.
|
boolean |
hasUserAnyPermissionOnWorkspace(Set<Object> workspacesContexts,
UserIdentity user,
Set<GroupIdentity> userGroups,
String rightId)
Returns true if the user has a permission on at least one object, directly or though groups, for a given rights and if the object is attached to the given context that is /${WorkspaceName} and its conversions.
|
boolean |
hasUserAnyReadAccessPermissionOnWorkspace(Set<Object> workspacesContexts,
UserIdentity user,
Set<GroupIdentity> userGroups)
Returns true if the user has a read access permission on at least one object, directly or though groups, for a given rights and if the object is attached to the given context that is /${WorkspaceName} and its conversions.
|
boolean |
isSupported(Object object)
Returns true if this access controller supports the given object
|
AccessController.AccessResult getPermission(UserIdentity user, Set<GroupIdentity> userGroups, String rightId, Object object)
user
- The user. Cannot be null.userGroups
- The groups the user belongs torightId
- The id of the right of the userobject
- The context object to check the accessAccessController.AccessResult getReadAccessPermission(UserIdentity user, Set<GroupIdentity> userGroups, Object object)
user
- The user. Cannot be null.userGroups
- The groups the user belongs toobject
- The context object to check the accessMap<String,AccessController.AccessResult> getPermissionByRight(UserIdentity user, Set<GroupIdentity> userGroups, Object object)
user
- The user. Cannot be null.userGroups
- The groups the user belongs toobject
- The context object to check the accessAccessController.AccessResult getPermissionForAnonymous(String rightId, Object object)
rightId
- The id of the right to checkobject
- The objectAccessController.AccessResult getReadAccessPermissionForAnonymous(Object object)
object
- The objectAccessController.AccessResult getPermissionForAnyConnectedUser(String rightId, Object object)
rightId
- The id of the right to checkobject
- The objectAccessController.AccessResult getReadAccessPermissionForAnyConnectedUser(Object object)
object
- The objectMap<UserIdentity,AccessController.AccessResult> getPermissionByUser(String rightId, Object object)
rightId
- The id of the right to checkobject
- The objectMap<UserIdentity,AccessController.AccessResult> getReadAccessPermissionByUser(Object object)
object
- The objectMap<GroupIdentity,AccessController.AccessResult> getPermissionByGroup(String rightId, Object object)
rightId
- The id of the right to checkobject
- The objectMap<GroupIdentity,AccessController.AccessResult> getReadAccessPermissionByGroup(Object object)
object
- The objectboolean hasUserAnyPermissionOnWorkspace(Set<Object> workspacesContexts, UserIdentity user, Set<GroupIdentity> userGroups, String rightId)
workspacesContexts
- The contexts to tests such as {"/${WorkspaceName}", "/repository", "/admin"}user
- The useruserGroups
- The groupsrightId
- The id of the right to checkboolean hasUserAnyReadAccessPermissionOnWorkspace(Set<Object> workspacesContexts, UserIdentity user, Set<GroupIdentity> userGroups)
workspacesContexts
- The contexts to tests such as {"/${WorkspaceName}", "/repository", "/admin"}user
- The useruserGroups
- The groupsboolean hasAnonymousAnyPermissionOnWorkspace(Set<Object> workspacesContexts, String rightId)
workspacesContexts
- The contexts to tests such as {"/${WorkspaceName}", "/repository", "/admin"}rightId
- The id of the right to checkboolean hasAnonymousAnyReadAccessPermissionOnWorkspace(Set<Object> workspacesContexts)
workspacesContexts
- The contexts to tests such as {"/${WorkspaceName}", "/repository", "/admin"}boolean hasAnyConnectedUserAnyPermissionOnWorkspace(Set<Object> workspacesContexts, String rightId)
workspacesContexts
- The contexts to tests such as {"/${WorkspaceName}", "/repository", "/admin"}rightId
- The id of the right to checkboolean hasAnyConnectedUserAnyReadAccessPermissionOnWorkspace(Set<Object> workspacesContexts)
workspacesContexts
- The contexts to tests such as {"/${WorkspaceName}", "/repository", "/admin"}boolean isSupported(Object object)
object
- The object to test