Class CommandSuggestionEvent
java.lang.Object
com.sk89q.worldedit.event.Event
com.sk89q.worldedit.event.platform.CommandSuggestionEvent
Posted when suggestions for auto-completion are requested for command input.
-
Constructor Summary
ConstructorsConstructorDescriptionCommandSuggestionEvent
(Actor actor, String arguments) Create a new instance. -
Method Summary
Modifier and TypeMethodDescriptiongetActor()
Get the actor that issued the command.Get the arguments.Get the list of suggestions that are to be presented.void
setSuggestions
(List<Substring> suggestions) Set the list of suggestions that are to be presented.
-
Constructor Details
-
CommandSuggestionEvent
Create a new instance.- Parameters:
actor
- the playerarguments
- the arguments
-
-
Method Details
-
getActor
Get the actor that issued the command.- Returns:
- the actor that issued the command
-
getArguments
Get the arguments.- Returns:
- the arguments
-
getSuggestions
Get the list of suggestions that are to be presented.Each Substring holds the replacement as the substring, and the replacement range as the original substring range.
- Returns:
- the list of suggestions
-
setSuggestions
Set the list of suggestions that are to be presented.- Parameters:
suggestions
- the list of suggestions
-