Package com.martiansoftware.jsap

Interface Summary
DefaultSource An interface describing an object as being able to produce a set of default values.
ExceptionMap A class for aggregating exceptions thrown by JSAP's parsing process.
Flagged Marks an argument as being "flagged" - that is, as having its value on the command line preceded by an indicator.
 

Class Summary
AbstractParameter Top-level abstraction of a parameter.
CommandLineTokenizer A utility class to parse a command line contained in a single String into an array of argument tokens, much as the JVM (or more accurately, your operating system) does before calling your programs' public static void main(String[] args) methods.
Defaults Stores a collection of default values, associated with their respective parameters by the parameters' unique IDs.
FlaggedOption An option that implements the Flagged interface.
IDMap A utility class to allow lookups of parameter IDs by short flag or long flag.
JSAP The core class of the JSAP (Java Simple Argument Parser) API.
JSAPResult Encapsulates the results of JSAP's parse() methods.
Option The base class from which FlaggedOption and UnflaggedOption are derived.
PropertyStringParser A StringParser subclass that provides a means for setting/getting properties.
QualifiedSwitch A QualifiedSwitch is a parameter that has something in common with a Switch, i.e., its presence or absence is significant, but different from a "pure" Switch it can have an additional value (or values) prefixed by a ':' sign that qualifies the Switch - making it behave like a FlaggedOption if a value is specified.
StringParser Class responsible for converting Strings into Objects.
Switch A Switch is a parameter whose presence alone is significant; another commonly used term for a Switch is "Flag." Switches use a BooleanStringParser internally, so their results can be obtained from a JSAPResult using the getBoolean() methods.

An example of a command line using a Switch is "dosomething -v", where "-v" might mean "verbose."
TestAll Runs all of the JSAP tests, including those in sub-packages.
TestCommandLineTokenizer This junit TestCase runs a barrage of tests against the CommandLineTokenizer.
TestDefaults Tests JSAP's handling of default values.
TestFlaggedOption  
TestJSAPConfiguration Tests the JSAPConfiguration class
TestOption Tests the Option class
TestParser Tests the Parser class.
TestSwitch Tests the Switch class.
TestUsageString Tests the ability to automatically create usage information.
UnflaggedOption An option whose meaning is derived from its position in the argument list rather than a flag that precedes it.
 

Exception Summary
IllegalMultipleDeclarationException An exception indicating that a parameter has illegally been declared multiple times.
JSAPException The base class for all of JSAP's exceptions.
ParseException A JSAPException subclass notifying the application of a parse error.
RequiredParameterMissingException An exception indicating that a required parameter was missing from the supplied arguments and defaults.
SyntaxException An exception indicating that a syntax error was encountered in the argument list.
UnknownFlagException An exception indicating that a unknown flag has been specified.
 



Copyright © 2002-2004, Martian Software, Inc.. All Rights Reserved.
For the latest version and documentation, please visit http://www.martiansoftware.com/jsap