Klasse CLIParser

java.lang.Object
de.dlr.proseo.ui.cli.parser.CLIParser

@Component public class CLIParser extends Object
Parser for the prosEO Command Line Interface Command line syntax is based on a YAML specification. The general command syntax is: "proseo" command [subcommand...] [option...] [parameter...]
Autor:
Dr. Thomas Bassler
  • Felddetails

    • TOP_LEVEL_COMMAND_NAME

      public static final String TOP_LEVEL_COMMAND_NAME
      The name of the top-level command
      Siehe auch:
  • Konstruktordetails

    • CLIParser

      public CLIParser()
  • Methodendetails

    • loadSyntax

      public void loadSyntax() throws FileNotFoundException, org.yaml.snakeyaml.error.YAMLException
      Load the command line syntax from the configured syntax file
      Löst aus:
      FileNotFoundException - if the given file could not be read
      org.yaml.snakeyaml.error.YAMLException - if the given file could not be parsed
    • getSyntax

      public CLISyntax getSyntax()
      Return the currently applicable syntax
      Gibt zurück:
      the syntax
    • parse

      public ParsedCommand parse(String commandString) throws ParseException, IOException
      Parse a command string using the given syntax structure
      Parameter:
      commandString - the command string to parse
      Gibt zurück:
      a command structure for execution
      Löst aus:
      ParseException - if an error is detected in the command syntax
      IOException - if an I/O error occurs during input tokenizing