CommandAPI
6.0.0
An API for the command UI introduced in Minecraft 1.13
|
An interface declaring methods required to override argument suggestions. More...
Public Member Functions | |
Argument | overrideSuggestions (String... suggestions) |
Override the suggestions of this argument with a String array. More... | |
Argument | overrideSuggestions (Collection< String > suggestions) |
Argument | overrideSuggestions (Function< CommandSender, String[]> suggestions) |
Override the suggestions of this argument with a function that maps the command sender to a String array. More... | |
Argument | overrideSuggestions (BiFunction< CommandSender, Object[], String[]> suggestions) |
Override the suggestions of this argument with a function that maps the command sender to a String array. More... | |
Optional< Function< SuggestionInfo, IStringTooltip[]> > | getOverriddenSuggestions () |
Returns a function that maps the command sender to a String array of suggestions for the current command, or null if this is not overridden. More... | |
Argument | overrideSuggestionsT (IStringTooltip... suggestions) |
Override the suggestions of this argument with an array of StringTooltips, that represents the String suggestion and a hover tooltip. More... | |
Argument | overrideSuggestionsT (Collection< IStringTooltip > suggestions) |
Override the suggestions of this argument with a collection of StringTooltips, that represents the String suggestion and a hover tooltip. More... | |
Argument | overrideSuggestionsT (Function< CommandSender, IStringTooltip[]> suggestions) |
Override the suggestions of this argument with a function mapping the command sender to an array of StringTooltips, that represents the String suggestion and a hover tooltip. More... | |
Argument | overrideSuggestionsT (BiFunction< CommandSender, Object[], IStringTooltip[]> suggestions) |
Override the suggestions of this argument with a function mapping the command sender and previously declared arguments to an array of StringTooltips, that represents the String suggestion and a hover tooltip. More... | |
Argument | replaceSuggestions (Function< SuggestionInfo, String[]> suggestions) |
Argument | replaceSuggestionsT (Function< SuggestionInfo, IStringTooltip[]> suggestions) |
An interface declaring methods required to override argument suggestions.
Optional<Function<SuggestionInfo, IStringTooltip[]> > dev.jorel.commandapi.arguments.IOverrideableSuggestions.getOverriddenSuggestions | ( | ) |
Returns a function that maps the command sender to a String array of suggestions for the current command, or null
if this is not overridden.
null
if there are no overridden suggestions. Implemented in dev.jorel.commandapi.arguments.Argument.
Argument dev.jorel.commandapi.arguments.IOverrideableSuggestions.overrideSuggestions | ( | BiFunction< CommandSender, Object[], String[]> | suggestions | ) |
Override the suggestions of this argument with a function that maps the command sender to a String array.
suggestions | the function to override suggestions with |
Implemented in dev.jorel.commandapi.arguments.Argument.
Argument dev.jorel.commandapi.arguments.IOverrideableSuggestions.overrideSuggestions | ( | Collection< String > | suggestions | ) |
suggestions | a collection of strings to override suggestions with |
Implemented in dev.jorel.commandapi.arguments.Argument.
Argument dev.jorel.commandapi.arguments.IOverrideableSuggestions.overrideSuggestions | ( | Function< CommandSender, String[]> | suggestions | ) |
Override the suggestions of this argument with a function that maps the command sender to a String array.
suggestions | the function to override suggestions with |
Implemented in dev.jorel.commandapi.arguments.Argument.
Argument dev.jorel.commandapi.arguments.IOverrideableSuggestions.overrideSuggestions | ( | String... | suggestions | ) |
Override the suggestions of this argument with a String array.
Typically, this is the supplier s -> suggestions
.
suggestions | the string array to override suggestions with |
Implemented in dev.jorel.commandapi.arguments.Argument.
Argument dev.jorel.commandapi.arguments.IOverrideableSuggestions.overrideSuggestionsT | ( | BiFunction< CommandSender, Object[], IStringTooltip[]> | suggestions | ) |
Override the suggestions of this argument with a function mapping the command sender and previously declared arguments to an array of StringTooltips, that represents the String suggestion and a hover tooltip.
suggestions | the suggestions and tooltips to override suggestions with |
Implemented in dev.jorel.commandapi.arguments.Argument.
Argument dev.jorel.commandapi.arguments.IOverrideableSuggestions.overrideSuggestionsT | ( | Collection< IStringTooltip > | suggestions | ) |
Override the suggestions of this argument with a collection of StringTooltips, that represents the String suggestion and a hover tooltip.
suggestions | the suggestions and tooltips to override suggestions with |
Implemented in dev.jorel.commandapi.arguments.Argument.
Argument dev.jorel.commandapi.arguments.IOverrideableSuggestions.overrideSuggestionsT | ( | Function< CommandSender, IStringTooltip[]> | suggestions | ) |
Override the suggestions of this argument with a function mapping the command sender to an array of StringTooltips, that represents the String suggestion and a hover tooltip.
suggestions | the suggestions and tooltips to override suggestions with |
Implemented in dev.jorel.commandapi.arguments.Argument.
Argument dev.jorel.commandapi.arguments.IOverrideableSuggestions.overrideSuggestionsT | ( | IStringTooltip... | suggestions | ) |
Override the suggestions of this argument with an array of StringTooltips, that represents the String suggestion and a hover tooltip.
suggestions | the suggestions and tooltips to override suggestions with |
Implemented in dev.jorel.commandapi.arguments.Argument.