cbeust/jcommander — pull request #172 by magnusvojbacke (2013-11-21 14:52:15+00:00)
Title: Issue #171, Issue #127: Methods w/o output parameters for parse and usag...

...e description.

This pull request suggests to add static convenience methods for parsing lists of arguments and getting the usage text for a "Parameter descriptor" object (i.e. an object with Parameter annotations) *without* using Output parameters. It relies, instead, on reflection.

This will make the API slightly easier to use in a functional manner and, in my opinion, just generally easier to understand and use:

Params myParams = JCommander.parse(Params.class, myArgs);
String usage = JCommander.usage(Params.class, myProgramName);

This pull request is intended to resolve Issue #171 https://github.com/cbeust/jcommander/issues/171 but it also kind of addresses Issue #127 https://github.com/cbeust/jcommander/issues/127