IBM InfoSphere Streams Version 4.1.0

Toolkit structure

A toolkit is organized as a directory in the file system and contains two kinds of artifacts, which are authored and generated. A toolkit information model file (info.xml) contains information about the toolkit, including its name.

Authored artifacts are created by developers and include function and operator implementations. Generated artifacts are created by running the system-provided spl-make-toolkit utility, which, among other operations, creates the toolkit index (toolkit.xml). When you create a toolkit, name the root directory after the toolkit.

The following is an overview of the overall toolkit structure and a sample toolkit directory. The authored files are marked with + and generated files are marked with *. It gives a minimalist but representative example of the toolkit structure. Additional directories and files might be stored as part of the toolkit.
Generic Structure
/+ <toolkit> 
   /+ info.xml
   /* toolkit.xml 
   /+ <name-space>
      /+ <spl-file>
      /+ native.function
         /+ function.xml
      /+ <operator>
         /+ MySource
            /+ <operator>.xml
            /+ <operator>_h.cgt
            /+ <operator>_cpp.cgt
            /* <operator>_h.pm
            /* <operator>_cpp.pm
Example Structure
/+ MyFirstToolkit
   /+info.xml
   /*toolkit.xml
   /+MyNamespace
      /+ MySPLapp.spl
   /+MyFunctions
      /+ native.function
            /+ function.xml
   /+ MyOperators
      /+ MySource
            /+ MySource.xml
            /+ MySource_h.cgt
            /+ MySource_cpp.cgt
            /* MySource_h.pm
            /* MySource_cpp.pm
      /+ MySink
            /+ MySink.xml
            /+ MySink_h.cgt
            /+ MySink_cpp.cgt
            /* MySink_h.pm
            /* MySink_cpp.pm
      /+ impl
            /+ nl
                /* MyResource.dat
                /* include
                   /* MyResource.h
                   /* MyResource.pm
                /+ en
                   /+ en_US
                      /+ MyResource.xlf
                   /+ en_GB
                      /+ MyResource.xlf
                /+ fr
                   /+ fr_FR
                      /+ MyResource.xlf
Note: Namespaces can traverse multiple directories, in which case their names are concatenated by the '.' character. For instance, spl/adapter and spl.adapter are both valid directory structures and result in the same namespace for operators that are contained in the leaf directories.