Package studio.mevera.imperat.command
Interface PermissionHolder
- All Known Subinterfaces:
AnnotatedParameter<S>,Command<S>,CommandParameter<S>,CommandUsage<S>,FlagParameter<S>,NumericParameter<S>
- All Known Implementing Classes:
AnnotationParameterDecorator,FlagCommandParameter,InputParameter,NumericParameterDecorator
public interface PermissionHolder
Represents an entity that can hold a permission.
This interface allows getting and setting a permission string.
-
Method Summary
Modifier and TypeMethodDescriptionvoidaddPermission(String permission) Adds a permission for this holder.Retrieves the permission associated with this holder.default booleanhasPermission(String permission)
-
Method Details
-
getPermissions
Retrieves the permission associated with this holder.- Returns:
- A set of permission strings, if no permissions are set, it will return an empty set.
-
addPermission
Adds a permission for this holder.- Parameters:
permission- the permission string to add, can benull.
-
hasPermission
-