Your Browser is not longer supported

Please use Google Chrome, Mozilla Firefox or Microsoft Edge to view the page correctly
Loading...

{{viewport.spaceProperty.prod}}

System exits for program libraries

&pagelevel(2)&pagelevel

With the aid of the system exits for program libraries (PLAM exits) systems support can monitor (and if necessary deny) access to the library members. The following functions are supported: open, close, delete and rename member. Each of these functions has a request and a return exit, i.e. before calling the function and after the operation has been carried out (cf. the table of PLAM exits below).

Selection is made via a separate exit, which is activated whenever the ATTACH library function is called. The exits for the member access functions can thus be limited to an acceptable minimum (performance).

Function

Type of exit

Exit number

Open member (OPEN ELEMENT)

request

005

return

006

Close member (CLOSE ELEMENT)

request

007

return

008

Delete member (DELETE ELEMENT)

request

055

return

056

Rename member (RENAME ELEMENT)

request

057

return

058

Open program library (ATTACH LIBRARY)


054

The following information is passed to the exit points:

R1 = A(exit parameter area)
R12 = A(TPR program manager)
R13 = A(save area of calling component)
R14 = A(indirect return)
R15 = A(exit routine)

Return code:

R15 =   X'000000RR'
        RR =   Return code of exit routine
               00  no error (005-008, 055-058)
                   library to be monitored (054)
               04  function is rejected (005, 006, 008, 055-058)
                   library not to be monitored (054)
R15 = X'000000RR'
   RR = Return code of exit routine
   00 no error (005-008, 055-058), library to be monitored (054
   04 function is rejected (005, 006, 008, 055-058), library not to be 
   monitored (054)

At the request exit systems support can reject the function call before it is performed (exit points 005, 055, 057).

At the return exit the function has already been performed (exit points 006, 008, 056, 058). With the exception of exit point 006 (OPEN ELEMENT) the action can no longer be revoked.

DSECT

All the exits for program libraries are provided with a parameter list with the same structure.

The DSECT for the parameter list can be generated by means of the EXnnn macro:

name EXnnn D[,[prefix],[ALL]]

nnn = 3-digit exit number

If ALL is not specified, only the fields supplied with values by the function are provided with names. If ALL is specified, a parameter list valid for all functions is generated. The parameter “prefix” enables the symbolic field names to be prefixed by a freely selectable alphabetic character.

All exits in the parameter list are provided with the current PLAM version and library name. If specified previously, LINK=name is stored. The type, name, version and variant of a library member are also stored in the parameter list. This is not true for:

  • ATTACH LIBRARY - there is no connection to the library member as yet.

  • OPEN ELEMENT - in the case of the request exit, the specifications for the library member may still be incomplete (see OPEN member exit 005).

The following table illustrates which fields have values supplied by PLAM for the different exit routines.

Fields supplied by PLAM

Exit routines

ATTACH

OPEN

CLOSE

DELETE

RENAME

054

005

006

007

008

056

057

058

059

PMRC

x

x

x

x

x

x

x

x

x

PMRC1

x

x

x

x

x

x

x

x

x

PMPLV

x

x

x

x

x

x

x

x

x

PMLIB

x

x

x

x

x

x

x

x

x

PMLINK

x

x

x

x

x

x

x

x

x

PMOPM


x

x







PMSLV


x

x







PMLVD


x

x







PMCLM




x

x





PMTYP


x

x

x

x

x

x

x

x

PMNAM


x

x

x

x

x

x

x

x

PMVER


x

x

x

x

x

x

x

x

PMVAR


x

x

x

x

x

x

x

x

PMDAT


x

x

x

x

x

x

x

x

PMTYP2








x

x

PMNAM2








x

x

PMVER2








x

x