Extending the C++ connector base class

In the C++ connector library, the connector base class is named GenGlobals. For a C++ connector, the base class methods are pure virtual methods. The GenGlobals class provides methods for connector startup and shut down, access to connector configuration properties, and utility methods for logging and tracing. To implement your own connector, you extend this connector base class.

Note:
For general information about the methods of the connector base class, see "Extending the connector base class".

To derive a connector base class for a C++ connector, follow these steps.

  1. Derive a class that inherits from the GenGlobals class, and include the header file GenGlobals.hpp. You might want to name the new base class with the name of the application, such as SAPGlobals.cpp.
    Note:
    For information on naming conventions for a connector, see Naming IBM WebSphere InterChange Server Components in the IBM WebSphere InterChange Server documentation set.
  2. Implement the GenGlobals pure virtual methods for the connector methods. For more information on how to create these virtual methods, see Table 52.
  3. Provide the connector framework with a handle to your global connector class.

    Table 52. Extending virtual methods of the GenGlobals class
    Virtual GenGlobals method Description For more information
    init() Initializes the application-specific component of the connector. "Initializing the connector"
    getVersion() Obtain the version of the connector's application-specific component. "Checking the connector version"
    getBOHandlerforBO() Obtain the business-object handler for the business objects. "Obtaining the C++ business object handler"
    doVerbFor() Process the request business object by performing its verb operation. "Creating a business object handler"
    pollForEvents() Poll event store to obtain application events and send them to the connector framework. "Polling for events"
    terminate() Perform cleanup operations for the connector shut down. "Shutting down the connector"

Copyright IBM Corp. 1997, 2003