|
CommandAPI 12.1.0
An API for the command UI introduced in Minecraft 1.13
|
Public Member Functions | |
| String | getSuggestion () |
| Returns the current suggestion that this class holds. | |
| Message | getTooltip () |
| Returns the current tooltip text that this class holds. | |
Static Public Member Functions | |
| static StringTooltip | ofBaseComponents (String suggestion, BaseComponent... tooltip) |
| Constructs a StringTooltip with a suggestion and a formatted bungee text component tooltip. | |
| static StringTooltip | ofAdventureComponent (String suggestion, ComponentLike tooltip) |
| Constructs a StringTooltip with a suggestion and a formatted adventure text component tooltip. | |
| static Collection< StringTooltip > | generateBaseComponents (Function< String, BaseComponent[]> tooltipGenerator, String... suggestions) |
Constructs a collection of StringTooltip objects from an array of suggestions, and a function which generates a formatted tooltip for each suggestion. | |
| static Collection< StringTooltip > | generateBaseComponents (Function< String, BaseComponent[]> tooltipGenerator, Collection< String > suggestions) |
Constructs a collection of StringTooltip objects from a collection of suggestions, and a function which generates a formatted tooltip for each suggestion. | |
| static Collection< StringTooltip > | generateAdventureComponents (Function< String, ComponentLike > tooltipGenerator, String... suggestions) |
Constructs a collection of StringTooltip objects from an array of suggestions, and a function which generates a tooltip formatted as an adventure ComponentLike for each suggestion. | |
| static Collection< StringTooltip > | generateAdventureComponents (Function< String, ComponentLike > tooltipGenerator, Collection< String > suggestions) |
Constructs a collection of StringTooltip objects from a collection of suggestions, and a function which generates a tooltip formatted as an adventure ComponentLike for each suggestion. | |
| static StringTooltip | ofString (String suggestion, String tooltip) |
| Constructs a StringTooltip with a suggestion and a string tooltip. | |
| static StringTooltip | ofMessage (String suggestion, Message tooltip) |
| Constructs a StringTooltip with a suggestion and a formatted tooltip. | |
| static StringTooltip | none (String suggestion) |
| Constructs a StringTooltip with a suggestion and no tooltip. | |
| static Collection< StringTooltip > | none (String... suggestions) |
Constructs a collection of StringTooltip objects from an array of suggestions, and no tooltips. | |
| static Collection< StringTooltip > | none (Collection< String > suggestions) |
Constructs a collection of StringTooltip objects from a collection of suggestions, and no tooltips. | |
| static Collection< StringTooltip > | generateStrings (UnaryOperator< String > tooltipGenerator, String... suggestions) |
Constructs a collection of StringTooltip objects from an array of suggestions, and a function which generates a string tooltip for each suggestion. | |
| static Collection< StringTooltip > | generateStrings (UnaryOperator< String > tooltipGenerator, Collection< String > suggestions) |
Constructs a collection of StringTooltip objects from a collection of suggestions, and a function which generates a string tooltip for each suggestion. | |
| static Collection< StringTooltip > | generateMessages (Function< String, Message > tooltipGenerator, String... suggestions) |
Constructs a collection of StringTooltip objects from an array of suggestions, and a function which generates a formatted tooltip for each suggestion. | |
| static Collection< StringTooltip > | generateMessages (Function< String, Message > tooltipGenerator, Collection< String > suggestions) |
Constructs a collection of StringTooltip objects from a collection of suggestions, and a function which generates a formatted tooltip for each suggestion. | |
Protected Member Functions | |
| BukkitStringTooltip (String suggestion, Message tooltip) | |
Static Protected Member Functions | |
| static< T > Collection< StringTooltip > | generate (Function< String, T > tooltipGenerator, BiFunction< String, T, StringTooltip > tooltipWrapper, String... suggestions) |
| Internal base method for the other generation types. | |
| static< T > Collection< StringTooltip > | generate (Function< String, T > tooltipGenerator, BiFunction< String, T, StringTooltip > tooltipWrapper, Collection< String > suggestions) |
| Internal base method for the other generation types. | |
| static< T > Collection< StringTooltip > | generate (Function< String, T > tooltipGenerator, BiFunction< String, T, StringTooltip > tooltipWrapper, Stream< String > suggestions) |
| Internal base method for the other generation types. | |
|
staticprotectedinherited |
Internal base method for the other generation types.
| <T> | the type of the tooltip |
| tooltipGenerator | tooltip generation function |
| tooltipWrapper | function which wraps suggestion and tooltip into a StringTooltip object |
| suggestions | collection of suggestions to provide to the user |
StringTooltip objects from the provided suggestion, wrapped using the above functions
|
staticprotectedinherited |
Internal base method for the other generation types.
| <T> | the type of the tooltip |
| tooltipGenerator | tooltip generation function |
| tooltipWrapper | function which wraps suggestion and tooltip into a StringTooltip object |
| suggestions | stream of suggestions to provide to the user |
StringTooltip objects from the provided suggestion, wrapped using the above functions
|
staticprotectedinherited |
Internal base method for the other generation types.
| <T> | the type of the tooltip |
| tooltipGenerator | tooltip generation function |
| tooltipWrapper | function which wraps suggestion and tooltip into a StringTooltip object |
| suggestions | array of suggestions to provide to the user |
StringTooltip objects from the provided suggestion, wrapped using the above functions
|
static |
Constructs a collection of StringTooltip objects from a collection of suggestions, and a function which generates a tooltip formatted as an adventure ComponentLike for each suggestion.
| tooltipGenerator | function which returns a formatted tooltip for the suggestion, an adventure ComponentLike |
| suggestions | collection of suggestions to provide to the user |
StringTooltip objects from the provided suggestions, with the generated formatted tooltips
|
static |
Constructs a collection of StringTooltip objects from an array of suggestions, and a function which generates a tooltip formatted as an adventure ComponentLike for each suggestion.
| tooltipGenerator | function which returns a formatted tooltip for the suggestion, an adventure ComponentLike |
| suggestions | array of suggestions to provide to the user |
StringTooltip objects from the provided suggestions, with the generated formatted tooltips
|
static |
Constructs a collection of StringTooltip objects from a collection of suggestions, and a function which generates a formatted tooltip for each suggestion.
| tooltipGenerator | function which returns a formatted tooltip for the suggestion, an array of BaseComponents |
| suggestions | collection of suggestions to provide to the user |
StringTooltip objects from the provided suggestions, with the generated formatted tooltips
|
static |
Constructs a collection of StringTooltip objects from an array of suggestions, and a function which generates a formatted tooltip for each suggestion.
| tooltipGenerator | function which returns a formatted tooltip for the suggestion, an array of BaseComponents |
| suggestions | array of suggestions to provide to the user |
StringTooltip objects from the provided suggestions, with the generated formatted tooltips
|
staticinherited |
Constructs a collection of StringTooltip objects from a collection of suggestions, and a function which generates a formatted tooltip for each suggestion.
| tooltipGenerator | function which returns a formatted tooltip for the suggestion |
| suggestions | collection of suggestions to provide to the user |
StringTooltip objects from the provided suggestions, with the generated formatted tooltips
|
staticinherited |
Constructs a collection of StringTooltip objects from an array of suggestions, and a function which generates a formatted tooltip for each suggestion.
| tooltipGenerator | function which returns a formatted tooltip for the suggestion |
| suggestions | array of suggestions to provide to the user |
StringTooltip objects from the provided suggestions, with the generated formatted tooltips
|
staticinherited |
Constructs a collection of StringTooltip objects from a collection of suggestions, and a function which generates a string tooltip for each suggestion.
| tooltipGenerator | function which returns a string tooltip for the suggestion |
| suggestions | collection of suggestions to provide to the user |
StringTooltip objects from the provided suggestions, with the generated string tooltips
|
staticinherited |
Constructs a collection of StringTooltip objects from an array of suggestions, and a function which generates a string tooltip for each suggestion.
| tooltipGenerator | function which returns a string tooltip for the suggestion |
| suggestions | array of suggestions to provide to the user |
StringTooltip objects from the provided suggestions, with the generated string tooltips
|
inherited |
Returns the current suggestion that this class holds.
Implements dev.jorel.commandapi.IStringTooltip.
|
inherited |
Returns the current tooltip text that this class holds.
Implements dev.jorel.commandapi.IStringTooltip.
|
staticinherited |
Constructs a collection of StringTooltip objects from a collection of suggestions, and no tooltips.
| suggestions | collection of suggestions to provide to the user |
StringTooltip objects from the suggestions, with no tooltips
|
staticinherited |
Constructs a StringTooltip with a suggestion and no tooltip.
| suggestion | the suggestion to provide to the user |
|
staticinherited |
Constructs a collection of StringTooltip objects from an array of suggestions, and no tooltips.
| suggestions | array of suggestions to provide to the user |
StringTooltip objects from the suggestions, with no tooltips
|
static |
Constructs a StringTooltip with a suggestion and a formatted adventure text component tooltip.
| suggestion | the suggestion to provide to the user |
| tooltip | the formatted tooltip to show to the user when they hover over the suggestion |
|
static |
Constructs a StringTooltip with a suggestion and a formatted bungee text component tooltip.
| suggestion | the suggestion to provide to the user |
| tooltip | the formatted tooltip to show to the user when they hover over the suggestion |
|
staticinherited |
Constructs a StringTooltip with a suggestion and a formatted tooltip.
| suggestion | the suggestion to provide to the user |
| tooltip | the formatted tooltip to show to the user when they hover over the suggestion |
|
staticinherited |
Constructs a StringTooltip with a suggestion and a string tooltip.
| suggestion | the suggestion to provide to the user |
| tooltip | the string tooltip to show to the user when they hover over the suggestion |