Function codes and the flow of I/O exit processing
The I/O exit control block contains a function code field. This is set by File Manager before the I/O exit is called. It indicates the type of I/O function being performed by File Manager. The I/O exit is given the opportunity to perform actions at the points named by the function codes during File Manager processing. The function codes are also discussed in Exit protocol. They are: Initialization, Termination, Open, Close, Read and Write.
- Open: After the "real" data set open
- Close: Before the "real" close
- Read: Immediately after a read from DASD (before File Manager truncation or padding or other changes)
- Write: Immediately before a write to DASD (after File Manager truncation or padding or other changes)
The Function Code is the key input that your I/O exit should use to determine what actions to take. The following sections discuss the flow of control and data during I/O exit processing by focussing on the call type, as determined by the function code.