Version 4.2.6 for Mainframes (Update)
 —  Utilities  —

Stub Generation

A stub subprogram (interface object) is a Natural subprogram that is used to connect the client's calling program to a subprogram on a server.

Client stub subprograms are actually not required if automatic Natural RPC (Remote Procedure Call) execution is used with the one important exception described below. However, it can be advantageous to generate stub subprograms as explained in Stubs and Automatic RPC Execution in the section Operating a Natural RPC Environment in the Natural Remote Procedure Call (RPC) documentation.

Note for EntireX RPC Servers:
It is recommended to generate a stub subprogram if you want to call an EntireX RPC server. In this case, you must use the appropriate SYSRPC stub generation function described in this section to define the same group structure and attributes (parameter direction) as in the IDL (Interface Definition Language) definition of the subprogram. If the IDL does not contain group structures, it is recommended to use the direct command COMPAT IDL before generating the stub subprogram. For details refer to Special Considerations for Calling EntireX RPC Servers.

Note for Reliable RPC:
It is recommended to generate a stub subprogram if you want to use reliable RPC. If the parameter definitions do not contain group structures, you must set COMPAT IDL before generating the stub subprogram. (For details refer to Special Considerations for Reliable RPC).

You can generate a stub subprogram from new parameter definitions or from existing definitions in a subprogram or a parameter data area (PDA).

Caution:
The subprogram or PDA used for generating a stub subprogram can no longer be referenced in the local environment on the client side. The stub generation function completely changes the source of the subprogram so that it becomes unusable for local program calls.

The following sections describe the functions and commands provided to generate single or multiple stub subprograms:

Top of page