CommandLineInterface.parseAndExecute

Parses the given args, and then executes the appropriate command (if one was found).

Notes: If an exception is thrown, the error message is displayed on screen (as well as the stack trace, for non-release builds) and then -1 is returned.

  1. int parseAndExecute(string[] args, IgnoreFirstArg ignoreFirst)
    class CommandLineInterface(Modules...)
    final
    int
    parseAndExecute
  2. int parseAndExecute(ArgPullParser args)

Parameters

args string[]

The args to parse.

ignoreFirst IgnoreFirstArg

Whether to ignore the first value of args or not. If args is passed as-is from the main function, then the first value will be the path to the executable, and should be ignored.

Return Value

Type: int

The status code returned by the command, or -1 if an exception is thrown.

See Also

The documentation for ArgPullParser to understand the format for args.

Meta