commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Leal (JIRA)" <>
Subject [jira] Created: (CLI-117) Improve the group option desing (ids, more than one instance, etc)
Date Mon, 05 Jun 2006 13:07:29 GMT
Improve the group option desing (ids, more than one instance, etc)

         Key: CLI-117
     Project: Commons CLI
        Type: Improvement

    Versions: Nightly Builds    
    Reporter: David Leal

I am ussing the group option and on my humble opionion it should be improved, for example:

1) API doesn't support for the moment a group of options like this:
- people

but for more than one instance of the group, for example:
- people -id id1 -size 1 -age 10 -people -id id2 size 2 age 20

so, the group option are the same for each people, but with id argument you can identify each
element of the group. 

2) There is no way to unique identify a option in a given group, for example: Now the following
syntax is not possible:
-id <name> 
- people

so, the general option name is id, and the group option is also id. When using the CommandLine.hasOption("-id"),
there is no way to distinguish if it is a group option or just a general option. On my opinion,
the group option should be checked if there are present using the root group option as prefix,
for example something like this: CommandLine.hasOption("-people|-id"), so we are clearly looking
for the group option -id from people and with: CommandLine.hasOption("-id") we look for general
-id option.

3) There is no clear the use of GroupBuilder.withMaximum() and GroupBulder.withMinimum(),
I expected to allow more than one group option on the command line, like I have commented
on 1), but it doesn't work and the API doesn't allow to distinguish each group instances.

Thanks in advance,


This message is automatically generated by JIRA.
If you think it was sent incorrectly contact one of the administrators:
For more information on JIRA, see:

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

View raw message