public class DefaultApplicationArguments extends java.lang.Object implements ApplicationArguments
ApplicationArguments.| Constructor and Description |
|---|
DefaultApplicationArguments(java.lang.String... args) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
containsOption(java.lang.String name)
Return whether the set of option arguments parsed from the arguments contains an
option with the given name.
|
java.util.List<java.lang.String> |
getNonOptionArgs()
Return the collection of non-option arguments parsed.
|
java.util.Set<java.lang.String> |
getOptionNames()
Return the names of all option arguments.
|
java.util.List<java.lang.String> |
getOptionValues(java.lang.String name)
Return the collection of values associated with the arguments option having the
given name.
|
java.lang.String[] |
getSourceArgs()
Return the raw unprocessed arguments that were passed to the application.
|
public DefaultApplicationArguments(java.lang.String... args)
public java.lang.String[] getSourceArgs()
ApplicationArgumentsgetSourceArgs in interface ApplicationArgumentspublic java.util.Set<java.lang.String> getOptionNames()
ApplicationArguments["foo", "debug"].getOptionNames in interface ApplicationArgumentspublic boolean containsOption(java.lang.String name)
ApplicationArgumentscontainsOption in interface ApplicationArgumentsname - the name to checktrue if the arguments contain an option with the given namepublic java.util.List<java.lang.String> getOptionValues(java.lang.String name)
ApplicationArguments[])["bar"])["bar", "baz"])nullgetOptionValues in interface ApplicationArgumentsname - the name of the optionpublic java.util.List<java.lang.String> getNonOptionArgs()
ApplicationArgumentsgetNonOptionArgs in interface ApplicationArguments