commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Berin Loritsch" <>
Subject RE: [CLI] Feature requests and submissions
Date Thu, 01 Aug 2002 14:34:04 GMT
About setting up options...

I am not sure how to do this in CLI--I will be checking the docs,
but I want to point out the following capabilities that Avalon
CLI has, which might help you in Commons CLI.

Avalon's CLI Parser has some constants to allow us to specify
information about our options like the following:


ARGUMENT_DISALLOWED -- The presence of an argument
                       following the option is an error
                       condition handled by the CLI parser

ARGUMENT_OPTIONAL -- The option may or may not have an argument
                     following.  If it is there, include it
                     with the option.  If not, there is no error

ARGUMENT_REQUIRED -- There is one and only one argument following
                     the option.  If it does not exist throw an
                     exception.  If there are more than one option
                     throw an exception.

ARGUMENT_REQUIRED_2 -- There are two arguments following the option.
                       If they do not exist throw an exception.  If
                       there are more than two arguments, throw an

They are used to enable the following types of CLI options:


-h -v -V

(help, verbose, version)  Flag style options


-taint test -L INFO

(taint checks, Logging level)  Turn on ***, with the optional level


-f filename

(file) Use ***


-Dhoser=beer -define endline eh?

(define) Supply to arguments for each option--usually for definition
         style options.

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message