Package org.jline.builtins
Interface Completers.CompletionEnvironment
- Enclosing class:
Completers
public static interface Completers.CompletionEnvironment
Interface defining the environment for command completion.
This interface provides methods to access command information and evaluate completion expressions in a specific environment context.
-
Method Summary
Modifier and TypeMethodDescriptioncommandName(String command) Gets the display name for a command.evaluate(LineReader reader, ParsedLine line, String func) Evaluates a function in the current environment context.Gets the set of available command names.Gets the available completions for commands.resolveCommand(String command) Resolves a command name to its canonical form.
-
Method Details
-
getCompletions
Map<String,List<Completers.CompletionData>> getCompletions()Gets the available completions for commands.- Returns:
- a map of command names to their completion data
-
getCommands
-
resolveCommand
-
commandName
-
evaluate
Evaluates a function in the current environment context.- Parameters:
reader- the line readerline- the parsed command linefunc- the function to evaluate- Returns:
- the result of the evaluation
- Throws:
Exception- if an error occurs during evaluation
-