Package org.openhab.core.io.console
Class ConsoleInterpreter
java.lang.Object
org.openhab.core.io.console.ConsoleInterpreter
This class provides generic methods for handling console input (i.e. pure strings).
- Author:
- Kai Kreuzer - Initial contribution, Markus Rathgeb - Change interface
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
execute
(Console console, ConsoleCommandExtension extension, String[] args) static String
getHelp
(String base, String separator, Collection<ConsoleCommandExtension> extensions) static String
getUsage
(Collection<ConsoleCommandExtension> consoleCommandExtensions) returns a CR-separated list of usage texts for all available commandsgetUsages
(Collection<ConsoleCommandExtension> consoleCommandExtensions) returns an array of the usage texts for all available commandsstatic void
printHelp
(Console console, String base, String separator, Collection<ConsoleCommandExtension> extensions)
-
Constructor Details
-
ConsoleInterpreter
public ConsoleInterpreter()
-
-
Method Details
-
getHelp
public static String getHelp(String base, String separator, Collection<ConsoleCommandExtension> extensions) -
printHelp
public static void printHelp(Console console, String base, String separator, Collection<ConsoleCommandExtension> extensions) -
execute
-
getUsage
returns a CR-separated list of usage texts for all available commands -
getUsages
returns an array of the usage texts for all available commands
-