java.lang.Object
eu.svjatoslav.commons.cli_helper.parameter_parser.Parser

public class Parser extends Object
Single commandline parameter can have any amount of arguments.
  • Constructor Details

    • Parser

      public Parser()
  • Method Details

    • add

      public <E extends Option> E add(E parameter)
    • findParameterByAlias

      public Option findParameterByAlias(String alias)
      Return parameter by given alias or null if no parameter exists for given alias.
      Parameters:
      alias - parameter alias
      Returns:
      found parameter or null if parameter was not found.
    • parse

      public boolean parse(String[] args)
      Parameters:
      args - commandline arguments
      Returns:
      true if no errors were found. false otherwise.
    • showHelp

      public void showHelp()