Interface ArgumentProcessor
-
- All Superinterfaces:
MenuElement
- All Known Implementing Classes:
ArgumentHandler
,BaseActionArgumentProcessor
,DecimalArgumentProcessor
,EntityTypeArgumentProcessor
,MaterialArgumentProcessor
,NumberArgumentProcessor
,PlayerArgumentProcessor
,SingleArgumentProcessor
,StoreArgumentProcessor
public interface ArgumentProcessor extends MenuElement
The base class for argument processors
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description String
getValue(String query, UUID uuid)
Get the valueOptional<String[]>
process(UUID uuid, String[] args)
Process the argumentsdefault Pair<Optional<List<String>>,String[]>
tabComplete(UUID uuid, String[] args)
Get the tab complete for the arguments-
Methods inherited from interface me.hsgamer.bettergui.api.menu.MenuElement
getMenu
-
-
-
-
Method Detail
-
process
Optional<String[]> process(UUID uuid, String[] args)
Process the arguments- Parameters:
uuid
- the UUID of the playerargs
- the arguments- Returns:
- the remaining arguments, or empty if the arguments are invalid
-
getValue
String getValue(String query, UUID uuid)
Get the value- Parameters:
query
- the queryuuid
- the UUID of the player- Returns:
- the value
-
tabComplete
default Pair<Optional<List<String>>,String[]> tabComplete(UUID uuid, String[] args)
Get the tab complete for the arguments- Parameters:
uuid
- the UUID of the playerargs
- the arguments- Returns:
- A pair of the optional suggestions and the remaining arguments. The optional suggestions can be null if the processor should be skipped, then the remaining arguments will be used for the next processor
-
-