isSuccess()

Checks if a command line option parsing succeeded.

Syntax

Getopt.isSuccess( )
  RETURNS BOOLEAN

Usage

This is a method for the Getopt type, that returns TRUE if last command line argument was processed successfully.

The isSuccess() method can be used after calling the getopt() method processing command line options in a loop, to detect correct options usage.

The processing status of the current option is typically checked with the return code of the getopt() method.

Example

IMPORT FGL getopt

MAIN
    DEFINE g getopt.Getopt
    ...
    WHILE g.getopt() == getopt.SUCCESS
        ...
    END WHILE

    IF g.isSuccess() THEN
        ...
    END IF

END MAIN