Interface MutablePermissionTree
- All Superinterfaces:
PermissionTree
A mutable permission tree.
-
Field Summary
Fields inherited from interface com.xpdustry.distributor.api.permission.PermissionTree
PERMISSION_PATTERN -
Method Summary
Modifier and TypeMethodDescriptiondefault voidClears all permissions.static MutablePermissionTreecreate()Creates a new mutable permission tree.default voidremovePermission(String permission) Removes the given permission from the tree.voidremovePermission(String permission, boolean all) default voidsetPermission(String permission, boolean state) Sets the permission with the given state.voidsetPermission(String permission, boolean state, boolean override) Sets the permission with the given state.default voidsetPermissions(PermissionTree tree) Sets the permissions from the given permission tree.default voidsetPermissions(PermissionTree tree, boolean override) Sets the permissions from the given permission tree.Methods inherited from interface com.xpdustry.distributor.api.permission.PermissionTree
getPermission, getPermissions
-
Method Details
-
create
Creates a new mutable permission tree. -
setPermission
Sets the permission with the given state.- Parameters:
permission- the permissionstate- the state
-
setPermission
Sets the permission with the given state.- Parameters:
permission- the permissionstate- the stateoverride- whether to override the child permissions with the new state
-
setPermissions
Sets the permissions from the given permission tree.- Parameters:
tree- the permission tree
-
setPermissions
Sets the permissions from the given permission tree.- Parameters:
tree- the permission treeoverride- whether to override the child permissions with the new state
-
removePermission
Removes the given permission from the tree. Essentially making itTriState.UNDEFINED.- Parameters:
permission- the permission
-
removePermission
-
clearPermissions
default void clearPermissions()Clears all permissions.
-