Common argument and the name of the library

The argument RAM-ARGUMENTS is passed to all of the functions providing required services. It contains the name of the library as well as additional information.

Here are the data declarations and code in the sample exit to access the library name in RAM-ARGUMENTS:

 01 RAM-ARGUMENTS.
    05 SOFTWARE-VERSION PIC S9(4) BINARY.
    05 REP-EXEC-SPEC-PTR          POINTER.
    05 REP-ID-SPEC-PTR            POINTER.
    05 REP-PARMS-SPEC-PTR         POINTER.

 01 REP-ID-SPEC.
    05 SOFTWARE-VERSION PIC S9(4) BINARY.
    05 RESOURCE-ID-TYPE PIC S9(4) BINARY.
    05 REP-NAME-STRING-PTR        POINTER.

 01 REP-NAME-STRING.
    05 REP-NAME-LEN PIC  9(4) BINARY.
    05 REP-NAME-GROUP.
       10 REP-NAME  PIC  X
                    OCCURS 1 TO 50 TIMES
                    DEPENDING ON REP-NAME-LEN.

GET-RAM-PARM2-RAM-ARGS.
     SET ADDRESS OF RAM-ARGUMENTS TO RAM-PARM2.
     SET ADDRESS OF REP-ID-SPEC TO REP-ID-SPEC-PTR.
     SET ADDRESS OF REP-NAME-STRING TO REP-NAME-STRING-PTR
     IF TRACELVL >= TRACEBAS THEN
       MOVE SPACES TO LOG-TEXT
       STRING "Repository name = " DELIMITED BY SIZE
              REP-NAME-GROUP DELIMITED BY SIZE
              INTO LOG-TEXT
       CALL LOGFUNC USING LOG-HOST, LOG-MODULE, LOG-TEXT
     END-IF.