NPA_Parse_Options

Parses the command line at load time for configuration options.

Thread Context:Blocking
Requirements:When used correctly, this function is called within the context of the module's initialization function (CDM_Load or HAM_Load), which is a blocking process.

Syntax

    LONG NPA_Parse_Options (
       LONG   npaHandle,
       LONG   screenID,
       BYTE  *commandLine
       );
    
    

Parameters

npaHandle
(IN) The CDM's or HAM's handle for using the NPA APIs, assigned during NPA_Register_CDM_Module or NPA_Register_HAM_Module, respectively.
screenID
(IN) Handle to the server console that was passed into the CDM_Load or HAM_Load function.
commandLine
(IN) Points to the characters entered on the command line at load time. Its value was passed into the CDM_Load or HAM_Load function.

Return Values

The following table lists return values and descriptions.

0

Successful

-1

Invalid npaHandle

-2

No matching options were found.

Remarks

NPA_Parse_Options is used to parse the command line parameters specified by the systems operator. After the command line is parsed, NPA_Parse_Options calls CDM_Check_Option or HAM_Check_Option so that the CDM or HAM can validate the command line options and set its I/O configuration.