Engine Developer Guide

Engine Developer Guide

Developing a Custom Component in C or C++

Developing a Custom Component in C or C++

  1. Create a C or C++ project.
  2. Add the following files to the project:
    General.c Utils.c
    You can find the files in the following directory:
    <INSTALL_DIR>/DataTransformation/samples/SDK/ExternalParameters/Cpp_SDK/Cpp
  3. Include all
    *.h
    files from the following directories:
    <INSTALL_DIR>/DataTransformation/samples/SDK/ExternalParameters/Cpp_SDK/Cpp/include api/include
  4. Set the linker option to add the following subdirectory:
    <INSTALL_DIR>/DataTransformation/api/lib
  5. Create a module that implements the appropriate functions. The following table describes the components that you can implement:
    Component Type
    Description
    Document processor
    Input Type: File
    Interface: CMXProcessFile
    Document processor
    Input type: Multiple files
    Interface: CMXProcessMultipleFiles
    Document processor
    Input type: Buffer
    Interface: CMXProcessBuffer
    Document processor
    Input type: C++ stream
    Interface: CMXProcessStream
    Transformer
    Input type: Null-terminated string
    Interface: CMXTransformBuffer
    Transformer
    Input type: Buffer input that is not null-terminated
    Interface: CMXTransformBinaryBuffer
    There are some restrictions on whether a single module can implement more than one of the above interfaces. For more information about the interfaces, see the
    External-Component C and C++ Interface Reference
    .
  6. For use on Windows platforms, compile the project to a DLL. For use on Linux or UNIX platforms, compile to a shared object.
  7. Store the DLL or the shared object in the
    <INSTALL_DIR>\DataTransformation\externLibs\user
    directory on every computer where you plan to use the component in a service.
  8. Create a script file that defines the display name of the component and its properties. Store the file in the
    autoInclude\user
    directory.
    For more information about this step, see Configuring an External Component.
    You can then use the external component in transformations.

0 COMMENTS

We’d like to hear from you!