Interface PermissionSet<PermissionType extends Permission>
-
- Type Parameters:
PermissionType
- The type of permission stored within this PermissionSet.
- All Known Subinterfaces:
ObjectPermissionSet
,SystemPermissionSet
- All Known Implementing Classes:
SimpleObjectPermissionSet
,SimpleSystemPermissionSet
public interface PermissionSet<PermissionType extends Permission>
An arbitrary set of permissions.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
addPermissions(Set<PermissionType> permissions)
Adds the specified permissions, if not already granted.Set<PermissionType>
getPermissions()
Returns a Set which contains all permissions granted within this permission set.void
removePermissions(Set<PermissionType> permissions)
Removes each of the specified permissions, if granted.
-
-
-
Method Detail
-
getPermissions
Set<PermissionType> getPermissions() throws org.apache.guacamole.GuacamoleException
Returns a Set which contains all permissions granted within this permission set.- Returns:
- A Set containing all permissions granted within this permission set.
- Throws:
org.apache.guacamole.GuacamoleException
- If an error occurs while retrieving permissions, or if permissions cannot be retrieved due to lack of permissions to do so.
-
addPermissions
void addPermissions(Set<PermissionType> permissions) throws org.apache.guacamole.GuacamoleException
Adds the specified permissions, if not already granted. If a specified permission is already granted, no operation is performed regarding that permission.- Parameters:
permissions
- The permissions to add.- Throws:
org.apache.guacamole.GuacamoleException
- If an error occurs while adding the permissions, or if permission to add permissions is denied.
-
removePermissions
void removePermissions(Set<PermissionType> permissions) throws org.apache.guacamole.GuacamoleException
Removes each of the specified permissions, if granted. If a specified permission is not granted, no operation is performed regarding that permission.- Parameters:
permissions
- The permissions to remove.- Throws:
org.apache.guacamole.GuacamoleException
- If an error occurs while removing the permissions, or if permission to remove permissions is denied.
-
-