Interface AsyncTabCompleteEvent.Completion
- Enclosing class:
AsyncTabCompleteEvent
public static interface AsyncTabCompleteEvent.Completion
A rich tab completion, consisting of a string suggestion, and a nullable
Component tooltip.-
Method Summary
Modifier and TypeMethodDescriptioncompletion(String suggestion) Create a newAsyncTabCompleteEvent.Completionfrom a suggestion string.completion(String suggestion, @Nullable Component tooltip) Create a newAsyncTabCompleteEvent.Completionfrom a suggestion string and a tooltipComponent.Get the suggestion string for thisAsyncTabCompleteEvent.Completion.tooltip()Get the suggestion tooltip for thisAsyncTabCompleteEvent.Completion.
-
Method Details
-
suggestion
String suggestion()Get the suggestion string for thisAsyncTabCompleteEvent.Completion.- Returns:
- suggestion string
-
tooltip
Get the suggestion tooltip for thisAsyncTabCompleteEvent.Completion.- Returns:
- tooltip component
-
completion
Create a newAsyncTabCompleteEvent.Completionfrom a suggestion string.- Parameters:
suggestion- suggestion string- Returns:
- new completion instance
-
completion
Create a newAsyncTabCompleteEvent.Completionfrom a suggestion string and a tooltipComponent.If the provided component is
null, the suggestion will not have a tooltip.- Parameters:
suggestion- suggestion stringtooltip- tooltip component, ornull- Returns:
- new completion instance
-