Support This Project Get i5/OS Programmer's Toolkit at Fast, secure and Free Open Source software downloads

i5/OS Programmer's Toolkit: ILE RPG Header for the System Entry Point Table (SEPT)

Go back to main page of project i5/OS Programmer's Toolkit .

ept54.rpgleinc declares index number for each entry in the System Entry Point Table (SEPT) of a V5R4M0 machine. The purpose of the ept54.rpgleinc to help ILE RPG programmers to improve their efficiency when invoking i5/OS APIs. Most APIs in form of program object have an particular entry in the SEPT (a system pointer to the program object). Calling such an API by name means one must first resolve a system pointer to it by name. Resolving a system pointer to an MI object residing in a crowded library such as QSYS is time-consuming comparing to using a resolved one. That's why the SEPT was designed. When an SEPT of a particurlar machine is initialized at the installation stage, system pointers to program objects in library QSYS in it remains unchanged even across IPLs. User programs or compiler generated programs take advantage of the SEPT to make faster API invocations.

ILE C/C++ programmers can utilize the SEPT conviniently by including ILE C header file <qliept.h>. An ILE C/C++ programmer can utilize a resolved system pointer stored in the SEPT when invoking an i5/OS API like the following:

# include <qliept.h>
// ...
  // call the Clear Data Queue (QCLRDTAQ) API to clear a *DTAQ
or like the following
# include <qliept.h>
// ...
  // save the system pointer obtained from the SEPT

  // call the Clear Data Queue (QCLRDTAQ) API to clear one *DTAQ
  clrdtaq("SOME_DTAQ ", "SOME_LIB  ");

  // call QCLRDTAQ to clear another *DTAQ
  clrdtaq("ANOTHER_Q ", "SOME_LIB  ");

The introduction of ept54.rpgleinc enables ILE RPG programmers to utilize the SEPT to invoke an i5/OS API in combination with system built-in _CALLPGMV. For example, in the following test programs of ept54.rpgleinc, t065.rpgle one of the operational assistant APIs, QEZSNDMG is invoked via the resolved system pointer to it in the SEPT.

     h dftactgrp(*no)

      /copy mih54
      /copy ept54

     d ept_ptr         s               *
     d septs           s               *   dim(7001)
     d                                     based(ept_ptr)
     d argv            s               *   dim(1)

           // address the SEPT
           ept_ptr = sysept();

      /if defined(*v5r4m0)
           // call Operational Assistant API Send Message (QEZSNDMG)
           callpgmv( septs(EPT_QEZSNDMG)
                   : argv
                   : 0);

           *inlr = *on;

To compile the above-mentioned ILE RPG program, remember to let the RPG compiler know where ept54.rpgleinc and mih54.rpgleinc can be found by setting proper value for parameter INCDIR.

Download and Install

You can download and install the ILE RPG Header for the SEPT from the a release package of the project. ept54.rpgleinc can be restored to your system via bin/rpginc.savf in a release package beginning from release 0.2.13 of the project. All releases of i5/OS Programmer's Toolkit can be found at:

You can also download the lasted version of it by the following link and upload it to your system by FTP: . Or check it out from the svn repository like the following:

svn export

Support This Project
Generated on Mon Oct 3 04:10:44 2011 for i5/OS Programmer's Toolkit: System-builtin Headers for ILE RPG by  doxygen 1.5.9