Class Parser

java.lang.Object
com.sun.enterprise.admin.cli.Parser

public class Parser extends Object
The Parser object is used to parse the command line and verify that the command line is CLIP compliant.
  • Constructor Details

    • Parser

      public Parser(String[] args, int start, Collection<org.glassfish.api.admin.CommandModel.ParamModel> options, boolean ignoreUnknown) throws org.glassfish.api.admin.CommandValidationException
      Parse the given command line arguments
      Parameters:
      args - command line arguments
      start - index in args to start parsing
      options - the valid options to consider while parsing
      ignoreUnknown - if true, unknown options are considered operands instead of generating an exception
      Throws:
      org.glassfish.api.admin.CommandValidationException - if command line parsing fails
  • Method Details

    • getOptions

      public org.glassfish.api.admin.ParameterMap getOptions()
      Returns a Map with all the options. The Map is indexed by the long name of the option.
      Returns:
      options
    • getOperands

      public List<String> getOperands()
      Returns the list of operands.
      Returns:
      list of operands
    • toString

      public String toString()
      Overrides:
      toString in class Object