Version 9.5 SP1
 —  EntireX C Wrapper  —

Introduction to C Wrapper

EntireX C Wrapper provides access to RPC-based components from C applications. It enables you to develop both client and server applications.

This document covers the following topics:


Description

The C Wrapper enables access to RPC servers for C client applications and access to C servers for any RPC client. The C Wrapper generation tools of the EntireX Workbench take as input a Software AG IDL file which describes the interface of the RPC and generates C sources that implement the functions and data types of the interface, and (internally) the related CVM file (see CVM File) if such a file has been generated.

graphics/cWrapper_overview.png

The generated functions can be compiled with the C compiler of your target platform.

The C Wrapper works as follows:

Top of page

Generic RPC C Runtime

In order to minimize the amount of code generated for a specific IDL, all service-type functionality required by the client interface object or the server interface is implemented in a generic RPC C runtime library. The generic RPC C runtime implements functions, for example:

Top of page

C Client Applications

For a given IDL file and the related CVM file, the Software AG IDL Compiler and a C code generation template for clients are used to generate client interface objects and header files. The source code generated by the C Wrapper can be compiled with your target C compiler. Application developers use the generated interface object(s) and the header file to write C applications that access RPC servers.

graphics/cWrapper_client.png

For more information, see Using the C Wrapper.

Top of page

C Server Application

The Software AG IDL Compiler and a C code generation template for servers are used to generate interface object(s) and a server (skeleton) for a specific IDL.

Application developers use the generated server (skeleton) to write their own server code for each program in the IDL. The source code is compiled and linked with your target C compiler and linker into interface object and server libraries. Your server library name needs to match the library name as specified in the IDL file. The interface object library has the same name as your server library prefixed with the letter "D".

graphics/cWrapper_rpcServer.png

For more information, see Using the C Wrapper.

Top of page