Section 8 Application Interface
Rev. 1.01 Mar. 17, 2008 Page 97 of 128
REJ10J1822-0101
• Specification
The server is started up by calling rpc_start_server() when SVR_STATIC has not been
specified or rpc_start_server_with_paramarea() when SVR_STATIC has been specified.
When SVR_AUTH has not been specified, however, the definitions of server ID and version in
__config. UlRPCServerID and __config. UlRPCServerVersion are ignored. Instead, the
macros RPCSVR_ID_<server name> and RPCSVR_VERS_<server name> output to <config
file>_public.h are taken as the server ID and version in starting up the server.
8.4 Server-Stub Function Table
The server-stub function table is rpc_server_info.ServerStubList, the table defined by
rpc_start_server() or rpc_start_server_with_paramarea() called by the server-initialization
function.
(1) With neither SVR_NOSTUBTBL nor SVR_NOINIT
RPCGEN generates the server-initialization function and server-stub function table. Only the
server-initialization function generated by RPCGEN looks up the server-stub function table. Thus
RPCGEN outputs the server-stub function table as static data to <config file>_svr.c.
(2) Without SVR_NOSTUBTBL and with SVR_NOINIT
RPCGEN does not generate the server-initialization function but does generate the server-stub
function table. RPCGEN outputs the server-stub function table in the form given below to <config
file>_svr.c. The server-initialization function provided in the application must look up the server-
stub function table to call rpc_start_server() or rpc_start_server_with_paramarea().
UINT32 (* const __rpcsvr_<server name>
_StubTable[])(rpc_server_stub_info *) =
{
<server-stub function name>,
<server-stub function name>,
};
<Server name> refers to the server name defined with SVR_NAME.