Package dev.jorel.commandapi
Class StringTooltip
java.lang.Object
dev.jorel.commandapi.StringTooltip
- All Implemented Interfaces:
IStringTooltip
Represents a suggestion for an argument with a hover tooltip text for that
suggestion. This class is to be used with normal suggestion overrides, via
the
Argument.overrideSuggestionsT method.-
Method Summary
Modifier and TypeMethodDescriptionReturns the current suggestion that this class holdsReturns the current tooltip text that this class holdsstatic StringTooltipConstructs a StringTooltip with a suggestion and no tooltipstatic StringTooltipConstructs a StringTooltip with a suggestion and a tooltip
-
Method Details
-
none
Constructs a StringTooltip with a suggestion and no tooltip- Parameters:
suggestion- the suggestion to provide to the user- Returns:
- a StringTooltip representing this suggestion
-
of
Constructs a StringTooltip with a suggestion and a tooltip- Parameters:
suggestion- the suggestion to provide to the usertooltip- the tooltip to show to the user when they hover over the suggestion- Returns:
- a StringTooltip representing this suggestion and tooltip
-
getSuggestion
Returns the current suggestion that this class holds- Specified by:
getSuggestionin interfaceIStringTooltip- Returns:
- the current suggestion that this class holds
-
getTooltip
Returns the current tooltip text that this class holds- Specified by:
getTooltipin interfaceIStringTooltip- Returns:
- the current tooltip text that this class holds
-