![]() |
Bukkit
1.4.7-R1.0
|
Holds information about a permission attachment on a Permissible object. More...
Public Member Functions | |
| PermissionAttachment (Plugin plugin, Permissible Permissible) | |
| Plugin | getPlugin () |
| Gets the plugin responsible for this attachment. | |
| void | setRemovalCallback (PermissionRemovedExecutor ex) |
| Sets an object to be called for when this attachment is removed from a Permissible. | |
| PermissionRemovedExecutor | getRemovalCallback () |
| Gets the class that was previously set to be called when this attachment was removed from a Permissible. | |
| Permissible | getPermissible () |
| Gets the Permissible that this is attached to. | |
| Map< String, Boolean > | getPermissions () |
| Gets a copy of all set permissions and values contained within this attachment. | |
| void | setPermission (String name, boolean value) |
| Sets a permission to the given value, by its fully qualified name. | |
| void | setPermission (Permission perm, boolean value) |
| Sets a permission to the given value. | |
| void | unsetPermission (String name) |
| Removes the specified permission from this attachment. | |
| void | unsetPermission (Permission perm) |
| Removes the specified permission from this attachment. | |
| boolean | remove () |
| Removes this attachment from its registered Permissible. | |
Holds information about a permission attachment on a Permissible object.
Definition at line 10 of file PermissionAttachment.java.
| org.bukkit.permissions.PermissionAttachment.PermissionAttachment | ( | Plugin | plugin, |
| Permissible | Permissible | ||
| ) |
Definition at line 16 of file PermissionAttachment.java.
References org.bukkit.plugin.Plugin.getDescription(), org.bukkit.plugin.PluginDescriptionFile.getFullName(), and org.bukkit.plugin.Plugin.isEnabled().
| Permissible org.bukkit.permissions.PermissionAttachment.getPermissible | ( | ) |
Gets the Permissible that this is attached to.
Definition at line 59 of file PermissionAttachment.java.
| Map<String, Boolean> org.bukkit.permissions.PermissionAttachment.getPermissions | ( | ) |
Gets a copy of all set permissions and values contained within this attachment.
This map may be modified but will not affect the attachment, as it is a copy.
Definition at line 70 of file PermissionAttachment.java.
| Plugin org.bukkit.permissions.PermissionAttachment.getPlugin | ( | ) |
Gets the plugin responsible for this attachment.
Definition at line 32 of file PermissionAttachment.java.
| PermissionRemovedExecutor org.bukkit.permissions.PermissionAttachment.getRemovalCallback | ( | ) |
Gets the class that was previously set to be called when this attachment was removed from a Permissible.
May be null.
Definition at line 50 of file PermissionAttachment.java.
Referenced by org.bukkit.permissions.PermissibleBase.removeAttachment().
| boolean org.bukkit.permissions.PermissionAttachment.remove | ( | ) |
Removes this attachment from its registered Permissible.
Definition at line 125 of file PermissionAttachment.java.
References org.bukkit.permissions.Permissible.removeAttachment().
Referenced by org.bukkit.permissions.PermissibleBase.addAttachment().
| void org.bukkit.permissions.PermissionAttachment.setPermission | ( | String | name, |
| boolean | value | ||
| ) |
Sets a permission to the given value, by its fully qualified name.
| name | Name of the permission |
| value | New value of the permission |
Definition at line 80 of file PermissionAttachment.java.
References org.bukkit.permissions.Permissible.recalculatePermissions().
Referenced by org.bukkit.permissions.PermissibleBase.addAttachment(), and org.bukkit.permissions.PermissionAttachment.setPermission().
| void org.bukkit.permissions.PermissionAttachment.setPermission | ( | Permission | perm, |
| boolean | value | ||
| ) |
Sets a permission to the given value.
| perm | Permission to set |
| value | New value of the permission |
Definition at line 91 of file PermissionAttachment.java.
References org.bukkit.permissions.Permission.getName(), org.bukkit.permissions.Permissible.recalculatePermissions(), and org.bukkit.permissions.PermissionAttachment.setPermission().
| void org.bukkit.permissions.PermissionAttachment.setRemovalCallback | ( | PermissionRemovedExecutor | ex | ) |
Sets an object to be called for when this attachment is removed from a Permissible.
May be null.
| ex | Object to be called when this is removed |
Definition at line 41 of file PermissionAttachment.java.
| void org.bukkit.permissions.PermissionAttachment.unsetPermission | ( | String | name | ) |
Removes the specified permission from this attachment.
If the permission does not exist in this attachment, nothing will happen.
| name | Name of the permission to remove |
Definition at line 103 of file PermissionAttachment.java.
References org.bukkit.permissions.Permissible.recalculatePermissions().
Referenced by org.bukkit.permissions.PermissionAttachment.unsetPermission().
| void org.bukkit.permissions.PermissionAttachment.unsetPermission | ( | Permission | perm | ) |
Removes the specified permission from this attachment.
If the permission does not exist in this attachment, nothing will happen.
| perm | Permission to remove |
Definition at line 115 of file PermissionAttachment.java.
References org.bukkit.permissions.Permission.getName(), org.bukkit.permissions.Permissible.recalculatePermissions(), and org.bukkit.permissions.PermissionAttachment.unsetPermission().