Class PluginPermission
java.lang.Object
eu.hexagonmc.spigot.annotation.meta.PluginPermission
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidAdds a child permission to this permission.booleanstatic PluginPermissionfrom(Permission annotation) Creates permission from an annotation.Gets all child permissions.The default behavior of this permission.The description of this permission.getName()The name of this permission.inthashCode()booleanremoveChild(String node) Removes child permission from this permission.voidSets the default behavior of this permission.voidsetDescription(String description) Sets the description of this permission.voidSets the name of this permission.toString()
-
Constructor Details
-
PluginPermission
Creates a new permission from a name.- Parameters:
name- The name of the permission
-
-
Method Details
-
from
Creates permission from an annotation. Parses the data stored in the annotation.- Parameters:
annotation- The annotation to parse for data- Returns:
- The new permission
- See Also:
-
setName
Sets the name of this permission.- Parameters:
name- The name to set
-
getName
The name of this permission.- Returns:
- The name
-
setDescription
Sets the description of this permission.- Parameters:
description- The description to set
-
getDescription
The description of this permission.- Returns:
- The description
-
setDefault
Sets the default behavior of this permission.- Parameters:
def- The default behavior to set- See Also:
-
getDefault
The default behavior of this permission.- Returns:
- The default behavior
- See Also:
-
addChild
Adds a child permission to this permission.- Parameters:
node- The node of the childstate- The state of the child.
-
getChilds
Gets all child permissions.- Returns:
- The child permissions
-
removeChild
Removes child permission from this permission.- Parameters:
node- The node of the child to remove- Returns:
- true if the command was removed false if it did not exist
-
toString
-
hashCode
public int hashCode() -
equals
-