Class AbstractSelector.BasicDescriptor
java.lang.Object
dev.kitteh.factions.permissible.selector.AbstractSelector.BasicDescriptor
- All Implemented Interfaces:
PermSelector.Descriptor
- Direct Known Subclasses:
AbstractRelationSelector.RelationDescriptor,AbstractRoleSelector.RoleDescriptor
- Enclosing class:
AbstractSelector
public static class AbstractSelector.BasicDescriptor
extends Object
implements PermSelector.Descriptor
-
Constructor Summary
ConstructorsConstructorDescriptionBasicDescriptor(String name, Supplier<String> displayName, Function<String, PermSelector> function) -
Method Summary
Modifier and TypeMethodDescriptionbooleanTrue if accepts empty.Creates this type of PermSelector based on the given input.net.kyori.adventure.text.ComponentName for display in chat.@Nullable StringGets instructions, if any exist.name()Name, used for serialization.withInstructions(Supplier<String> instructions) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface dev.kitteh.factions.permissible.PermSelector.Descriptor
options
-
Constructor Details
-
BasicDescriptor
-
-
Method Details
-
create
Description copied from interface:PermSelector.DescriptorCreates this type of PermSelector based on the given input.- Specified by:
createin interfacePermSelector.Descriptor- Parameters:
input- input- Returns:
- PermSelector
-
name
Description copied from interface:PermSelector.DescriptorName, used for serialization.- Specified by:
namein interfacePermSelector.Descriptor- Returns:
- name
-
displayName
public net.kyori.adventure.text.Component displayName()Description copied from interface:PermSelector.DescriptorName for display in chat.- Specified by:
displayNamein interfacePermSelector.Descriptor- Returns:
- chat display name
-
acceptEmpty
-
acceptsEmpty
public boolean acceptsEmpty()Description copied from interface:PermSelector.DescriptorTrue if accepts empty. Only default is the AllSelector.- Specified by:
acceptsEmptyin interfacePermSelector.Descriptor- Returns:
- true if this type doesn't need a value
-
withInstructions
-
instructions
Description copied from interface:PermSelector.DescriptorGets instructions, if any exist. Given if no options are provided.- Specified by:
instructionsin interfacePermSelector.Descriptor- Returns:
- instructions
-