Package org.bremersee.acl
Interface Acl
- All Known Implementing Classes:
Acl.AclImpl
public interface Acl
The access control list.
- Author:
- Christian Bremer
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic classThe al builder.static classThe acl implementation. -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic Acl.AclBuilderbuilder()Builder acl builder.getOwner()Gets owner.Returns the entries of this access control list.modify(AccessControlListModifications mods, AclUserContext userContext, AccessEvaluation accessEvaluation, Collection<String> permissions) Modifies the access control list.static Aclwith(String owner, Collection<String> defaultPermissions, Collection<String> adminRoles) With acl.
-
Field Details
-
OWNER
The constant OWNER.- See Also:
-
ENTRIES
The constant ENTRIES.- See Also:
-
-
Method Details
-
builder
Builder acl builder.- Returns:
- the acl builder
-
with
With acl.- Parameters:
owner- the ownerdefaultPermissions- the default permissionsadminRoles- the admin roles- Returns:
- the acl
-
getOwner
String getOwner()Gets owner.- Returns:
- the owner
-
getPermissionMap
Returns the entries of this access control list. The key of the map is the permission. This map is normally unmodifiable.- Returns:
- the map
-
modify
default Optional<Acl> modify(AccessControlListModifications mods, AclUserContext userContext, AccessEvaluation accessEvaluation, Collection<String> permissions) Modifies the access control list. If the modification forbidden, an empty optional will be returned, otherwise the modified access control list.- Parameters:
mods- the modificationsuserContext- the user contextaccessEvaluation- the access evaluationpermissions- the permissions- Returns:
- the optional
-