| Package | Description |
|---|---|
| me.lucko.helper.command | |
| me.lucko.helper.command.argument | |
| me.lucko.helper.command.functional |
| Modifier and Type | Method and Description |
|---|---|
void |
Command.call(CommandContext<?> context)
Calls the command handler
|
List<String> |
Command.callTabCompleter(CommandContext<?> context)
Calls the command tab completer
|
static void |
CommandInterruptException.makeAssertion(boolean condition,
String failMsg)
Makes an assertion about a condition.
|
| Modifier and Type | Method and Description |
|---|---|
default CommandInterruptException |
ArgumentParser.generateException(int missingArgumentIndex)
Generates a
CommandInterruptException for when parsing fails due to the lack of an argument. |
default CommandInterruptException |
ArgumentParser.generateException(String s)
Generates a
CommandInterruptException for when parsing fails with the given content. |
| Modifier and Type | Method and Description |
|---|---|
static <T> ArgumentParser<T> |
ArgumentParser.of(Function<String,Optional<T>> parseFunction,
Function<String,CommandInterruptException> generateExceptionFunction) |
| Modifier and Type | Method and Description |
|---|---|
default void |
Argument.assertPresent()
Asserts that the permission is present
|
default T |
ArgumentParser.parseOrFail(Argument argument)
Parses the value from an argument, throwing an interrupt exception if
parsing failed.
|
default <T> T |
Argument.parseOrFail(ArgumentParser<T> parser) |
default <T> T |
Argument.parseOrFail(Class<T> clazz) |
default T |
ArgumentParser.parseOrFail(String s)
Parses the value from a string, throwing an interrupt exception if
parsing failed.
|
default <T> T |
Argument.parseOrFail(com.google.common.reflect.TypeToken<T> type) |
| Modifier and Type | Method and Description |
|---|---|
List<String> |
FunctionalTabHandler.handle(CommandContext<T> c)
Executes the tab completer using the given command context and returns the completions.
|
void |
FunctionalCommandHandler.handle(CommandContext<T> c)
Executes the handler using the given command context
|
Copyright © 2022. All rights reserved.