Table of Contents

Search

  1. Preface
  2. Introduction to Data Transformation
  3. Data Processor Transformation
  4. Wizard Input and Output Formats
  5. Relational Input and Output
  6. Using the IntelliScript Editor
  7. XMap
  8. Libraries
  9. Schema Object
  10. Command Line Interface
  11. Scripts
  12. Parsers
  13. Script Ports
  14. Document Processors
  15. Formats
  16. Data Holders
  17. Anchors
  18. Transformers
  19. Actions
  20. Serializers
  21. Mappers
  22. Locators, Keys, and Indexing
  23. Streamers
  24. Validators, Notifications, and Failure Handling
  25. Validation Rules
  26. Custom Script Components

User Guide

User Guide

Configuring a Custom Component

Configuring a Custom Component

After you develop a custom component, you must prepare a Script file that defines the component. You cannot prepare the TGP file in the IntelliScript editor. Instead, you must prepare it in a text editor.
After you install the component and the TGP file, you can configure the custom component in the IntelliScript editor.
  1. Create a text file and save it with a
    *.tgp
    extension.
    You can define more than one external component in a single TGP file.
  2. For each property that your external component supports, add lines such as the following to the TGP file:
    profile <CustomPropertyName1> ofPT <DataType> { paramName = "<CustomPropertyName1>" ; }
    <CustomPropertyName1>
    is the name of a property that you want to display in the IntelliScript editor.
    <DataType>
    is the data type of the property. The supported data types are
    NamedParamIntT
    for an integer property,
    NamedParamBoolT
    for a boolean property,
    NamedParamStringT
    for a string property, or
    NamedParamListT
    for a property that is a list of strings.
  3. For each external component that you wish to define, add lines such as the following to the TGP file:
    profile <ExternalComponentName> ofPT <ComponentType> { jclass = "<ClassName>" ; param1 = <CustomPropertyName1>() ; param2 = <CustomPropertyName2>() ; }
    <ExternalComponentName>
    is the name of the external component that you want to display in the IntelliScript editor.
    <ComponentType>
    is one of the following values:
    For
    ComponentType
    A Java document processor with 0 to 4 properties
    ExternalJavaProcessorNoParamsT ExternalJavaProcessor1ParamsT ExternalJavaProcessor2ParamsT ...
    A Java transformer with 0 to 10 properties
    ExternalJavaTransformerNoParamsT ExternalJavaTransformer1ParamsT ExternalJavaTransformer2ParamsT ...
    <ClassName>
    is the fully qualified name of the Java class. On Windows,
    <DllName>
    is the name of the DLL, without the
    *.dll
    extension. On Linux or UNIX, it is the name of the shared object, without the
    lib
    prefix or the
    *.so
    , extension.
    <CustomPropertyName1>
    and
    <CustomPropertyName2>
    are the names of the properties that you configured in step 2.
  4. Save the
    *.tgp
    file.
  5. Store the file in the
    DataTransformation\autoInclude\user
    subdirectory of the installation directory of every computer where you want to use the component.
  6. If the Developer tool is open, close it and re-open it.
  7. If an
    autoInclude
    error is displayed, review the TGP file for syntax errors or naming inconsistencies, and open the Developer tool again.
  8. Open a project and insert the custom component in the Script. The custom component name, which you assigned in step 3 above, appears in the IntelliScript drop-down list. The IntelliScript editor displays its properties.

0 COMMENTS

We’d like to hear from you!