Interface PermissionManager
- All Known Subinterfaces:
- PluginManager
- All Known Implementing Classes:
- SimplePluginManager
- 
Method SummaryModifier and TypeMethodDescriptionvoidaddPermission(@NotNull Permission perm) Adds aPermissionto this plugin manager.voidaddPermissions(@NotNull List<Permission> perm) Adds a list of permissions.voidClears the current registered permissinos.getDefaultPermissions(boolean op) Gets the default permissions for the given op statusgetDefaultPermSubscriptions(boolean op) Gets a set containing all subscribedPermissibles to the given default list, by op statusgetPermission(@NotNull String name) Gets aPermissionfrom its fully qualified nameGets a set of all registered permissions.getPermissionSubscriptions(@NotNull String permission) Gets a set containing all subscribedPermissibles to the given permission, by namevoidRecalculates the defaults for the givenPermission.voidremovePermission(@NotNull String name) Removes aPermissionregistration from this plugin manager.voidRemoves aPermissionregistration from this plugin manager.voidsubscribeToDefaultPerms(boolean op, @NotNull Permissible permissible) Subscribes to the given Default permissions by operator statusvoidsubscribeToPermission(@NotNull String permission, @NotNull Permissible permissible) Subscribes the given Permissible for information about the requested Permission, by name.voidunsubscribeFromDefaultPerms(boolean op, @NotNull Permissible permissible) Unsubscribes from the given Default permissions by operator statusvoidunsubscribeFromPermission(@NotNull String permission, @NotNull Permissible permissible) Unsubscribes the given Permissible for information about the requested Permission, by name.
- 
Method Details- 
getPermissionGets aPermissionfrom its fully qualified name- Parameters:
- name- Name of the permission
- Returns:
- Permission, or null if none
 
- 
addPermissionAdds aPermissionto this plugin manager.If a permission is already defined with the given name of the new permission, an exception will be thrown. - Parameters:
- perm- Permission to add
- Throws:
- IllegalArgumentException- Thrown when a permission with the same name already exists
 
- 
removePermissionRemoves aPermissionregistration from this plugin manager.If the specified permission does not exist in this plugin manager, nothing will happen. Removing a permission registration will not remove the permission from any Permissibles that have it.- Parameters:
- perm- Permission to remove
 
- 
removePermissionRemoves aPermissionregistration from this plugin manager.If the specified permission does not exist in this plugin manager, nothing will happen. Removing a permission registration will not remove the permission from any Permissibles that have it.- Parameters:
- name- Permission to remove
 
- 
getDefaultPermissionsGets the default permissions for the given op status- Parameters:
- op- Which set of default permissions to get
- Returns:
- The default permissions
 
- 
recalculatePermissionDefaultsRecalculates the defaults for the givenPermission.This will have no effect if the specified permission is not registered here. - Parameters:
- perm- Permission to recalculate
 
- 
subscribeToPermissionvoid subscribeToPermission(@NotNull @NotNull String permission, @NotNull @NotNull Permissible permissible) Subscribes the given Permissible for information about the requested Permission, by name.If the specified Permission changes in any form, the Permissible will be asked to recalculate. - Parameters:
- permission- Permission to subscribe to
- permissible- Permissible subscribing
 
- 
unsubscribeFromPermissionvoid unsubscribeFromPermission(@NotNull @NotNull String permission, @NotNull @NotNull Permissible permissible) Unsubscribes the given Permissible for information about the requested Permission, by name.- Parameters:
- permission- Permission to unsubscribe from
- permissible- Permissible subscribing
 
- 
getPermissionSubscriptionsGets a set containing all subscribedPermissibles to the given permission, by name- Parameters:
- permission- Permission to query for
- Returns:
- Set containing all subscribed permissions
 
- 
subscribeToDefaultPermsSubscribes to the given Default permissions by operator statusIf the specified defaults change in any form, the Permissible will be asked to recalculate. - Parameters:
- op- Default list to subscribe to
- permissible- Permissible subscribing
 
- 
unsubscribeFromDefaultPermsUnsubscribes from the given Default permissions by operator status- Parameters:
- op- Default list to unsubscribe from
- permissible- Permissible subscribing
 
- 
getDefaultPermSubscriptionsGets a set containing all subscribedPermissibles to the given default list, by op status- Parameters:
- op- Default list to query for
- Returns:
- Set containing all subscribed permissions
 
- 
getPermissionsGets a set of all registered permissions.This set is a copy and will not be modified live. - Returns:
- Set containing all current registered permissions
 
- 
addPermissionsAdds a list of permissions.This is meant as an optimization for adding multiple permissions without recalculating each permission. - Parameters:
- perm- permission
 
- 
clearPermissionsvoid clearPermissions()Clears the current registered permissinos.This is used for reloading. 
 
-