Exit Program for Open Directory (QHFOPNDR) API


  Required Parameter Group:

1 Operation (OPNDR) Input Char(5)
2 File system job handle Input Char(16)
3 Reserved Input Char(20)
4 Open directory handle Output Char(16)
5 Path name Input Char(*)
6 Path name length Input Binary(4)
7 Open information Input Char(6)
8 Attribute selection table Input Char(4)
9 Length of attribute selection table Input Binary(4)

Before applications can use the Open Directory (QHFOPNDR) API with your file system, you must:

  1. Write an exit program that performs the open directory operation on behalf of the API. For a detailed description of the API and its calling parameters, see Open Directory (QHFOPNDR) API.

  2. Give the exit program's name when you register the file system with the Register File System (QHFRGFS) API.

After that, when an application calls the QHFOPNDR API, the API calls your exit program and passes it the parameters specified by the application. Your exit program performs the work and returns any data to the API. The API passes the data back to the calling application.


Authorities and Locks

None.


Required Parameter Group

The following shows the input parameters that the API passes to your exit program and the output parameter that the exit program must pass back to the API:

Operation (OPNDR)
INPUT; CHAR(5)

The abbreviation for the operation being performed (OPNDR).

File system job handle
INPUT; CHAR(16)

The work area or job identifier used by the file system.

Reserved
INPUT; CHAR(20)

Reserved for future use. This parameter is set to blanks.

Except as noted, the following parameters are the same as the parameters for the API.

Open directory handle
OUTPUT; CHAR(16)

Path name
INPUT; CHAR(*)

The API removes the file system name before passing the path name to the exit program.

Path name length
INPUT; BINARY(4)

Open information
INPUT; CHAR(6)

The exit program can ignore character 2, which describes the type of open operation to perform. This field is used by HFS support during job cleanup if the job ends before the file is closed.

Attribute selection table
INPUT; CHAR(*)

Length of the attribute selection table
INPUT; BINARY(4)

API Functions

The QHFOPNDR API performs the standard functions described in Standard HFS API Functions. The API does not validate the attribute selection table in any way.


Exit Program Requirements

You must create an exit program that performs the standard functions described in Standard HFS Exit Program Requirements and these additional functions:


Error Messages for Exit Program Use

This section lists the messages that the exit program can return to the API.

Message ID Error Message Text
CPF1F01 E Directory name not valid.
CPF1F02 E Directory not found.
CPF1F06 E Directory in use.
CPF1F07 E Authority not sufficient to access directory.
CPF1F08 E Damaged directory.
CPF1F41 E Severe error occurred while addressing parameter list.
CPF1F43 E Attribute name not valid.
CPF1F45 E Attribute selection table not valid.
CPF1F48 E Path name not valid.
CPF1F49 E Open information value not valid.
CPF1F62 E Requested function failed.
CPF1F66 E Storage needed exceeds maximum limit for user profile &1.
CPF1F71 E Exception specific to file system occurred.
CPF1F73 E Not authorized to use command.
CPF1F74 E Not authorized to object.
CPF1F75 E Error occurred during start-job-session function.
CPF1F77 E Severe parameter error occurred on call to file system.


Exit Program Introduced: V2R1
Top | Hierarchical File System APIs | APIs by category