oaOptional: An optional argument. It must be given as --option=argument or (short form) -o=argument.
If you use a short form and you combine many short option names into one parameter, then only the last option may have an argument. For example -abc=blah is equivalent to -a -b -c=blah.
oaRequired: A required argument. It must be given as for oaOptional, but this time the equal sign is not needed (we know anyway that following parameter must be an argument). So the following versions are possible:
--option=argument # long form, as one parameter
--option argument # long form, as two parameters
-o=argument # short form, as one parameter
-o argument # short form, as two parameters
oaRequired2Separate: We require a specified (more than one) argument. All of the arguments must be specified as separate parameters, like
The option number in the Options table (zero-based).
HasArgument
Says if you have a single argument in the Argument parameter. Always False when your option has oaNone or oaRequiredXSeparate. Always True when your option has oaRequired. For oaOptional, this is how you know if the optional argument was used.
Argument
A single argument for oaRequired or oaOptional, only if HasArgument. Otherwise empty string.
SeparateArgs
For options using oaRequiredXSeparate, your arguments are here. You get exactly as many argument as your oaRequiredXSeparate requested, the rest of SeparateArgs is empty strings.
Data
This is the OptionProcData value you passed to TParameters.Parse, use this to pass some pointer to your callback.
Command-line parameters. Initialized from standard ParamStr(0) ... ParamStr(ParamCount). Can be later modified, which is good — you can remove handled parameters. You also have all the methods of TCastleStringList class (e.g. you can assign to another TCastleStringList instance).