- java.lang.Object
-
- net.sourceforge.argparse4j.internal.ParseState
-
class ParseState extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description java.lang.String[]argsArray of arguments.(package private) booleanconsumedSeparatorTrue if special argument "--" is found and consumed.(package private) ArgumentParserExceptiondeferredExceptionDeferred exception encountered while parsing.(package private) intindexIndex in args array, which points next argument to process.(package private) intlastFromFileArgIndexIndex inargsarray, which points to the last argument read from file.(package private) booleannegNumFlagTrue if negative number like flag is registered in the parser.(package private) java.util.List<java.lang.String>posArgArgsAccumulated positional arguments we have seen so far.(package private) intposArgConsumedThe number of arguments (well, parameters) consumed for the current positional Argument object.(package private) intposArgIndexIndex of positional argument (Argument object) we are currently processing.(package private) java.util.List<java.lang.String>unknownAccumulated unknown arguments, if not null.
-
Constructor Summary
Constructors Constructor Description ParseState(java.lang.String[] args, boolean negNumFlag, java.util.List<java.lang.String> unknown)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) java.lang.StringgetArg()(package private) booleanisArgAvail()(package private) voidresetArgs(java.lang.String[] args)(package private) voidresetPosArgs()
-
-
-
Field Detail
-
args
public java.lang.String[] args
Array of arguments.
-
index
int index
Index in args array, which points next argument to process.
-
lastFromFileArgIndex
int lastFromFileArgIndex
Index inargsarray, which points to the last argument read from file. -1 means that no argument is read from file. If arguments are read from file recursively (e.g., argument file is found in argument file), this value is properly extended to point to the actual last argument by position.
-
consumedSeparator
boolean consumedSeparator
True if special argument "--" is found and consumed.
-
negNumFlag
boolean negNumFlag
True if negative number like flag is registered in the parser.
-
deferredException
ArgumentParserException deferredException
Deferred exception encountered while parsing. This will be thrown after parsing completed and no other exception was thrown.
-
posArgIndex
int posArgIndex
Index of positional argument (Argument object) we are currently processing.
-
posArgConsumed
int posArgConsumed
The number of arguments (well, parameters) consumed for the current positional Argument object.
-
posArgArgs
java.util.List<java.lang.String> posArgArgs
Accumulated positional arguments we have seen so far.
-
unknown
java.util.List<java.lang.String> unknown
Accumulated unknown arguments, if not null.
-
-