Essential and Additional Files

The following image shows a standard set of files for creating a Python-based integration node.

In the Python code inside the *_cmn.py file, you can import other libraries, allowing you to add a larger package of files to a complex integration plugin. With each additional *_cmn.py file, you provide an additional node in optiSLang’s module library. For the sake of organizational clarity, modularity, reusability, and testability, it can be beneficial to keep only small portions of code in the *_cmn.py files and concentrate the function and class definitions in a library of one or several files to import from. This way, you can create multiple nodes which build on a common modular library.

Node Python Script (Essential)

This file is the only truly essential one. This file, when it contains a viable set of implemented functions can be sufficient to create a simple custom integration node.

File name convention: *_cmn.py.

Configuration File (Essential)

The configuration file allows you to set options determining the general function and appearance of your integration plugin.

File name convention: *_cmn.json

For more details, see Configuration Files for Nodes.

Icon File

You can provide an icon for optiSLang to display on the node and make them easily recognizable. Accepted file types are .svg, .ico, .png, .jpg, .jpeg, and .bmp. Use the alpha channel for transparency. optiSLang uses color shading for depicting states, for example, running nodes are blue, failure states appear reddish. Those color messages are blocked if the quadratic icon does not contain transparent areas.

File name convention: *_cmn.svg, *_cn.ico, *_cmn.png, *_cmn.jpg, *_cmn.jpeg, *_cmn.bmp.

QML Files

These file enables you to design a graphical user interface for settings using the Qt markup language (QML). The settings user interface is embedded in the central area of the node edit dialog box. QML files are optional.

When you implement a QML-based settings user interface, you can offer fields and buttons with Qt-powered file and directory browser capabilities for a path setting. This compares to a simple string entry field displayed by the edit dialog box when you are not using QML. Check out the different demonstrators to see the differences.

If not present, then optiSLang falls back to displaying a vertical stacking of generic user interface elements. Working with that fallback level, you cannot control the logic of settings combinations or range of useful values. If a user enters an impossible combination of values in the edit dialog box, the only way of showing the problem is to throw an error in the CI code at runtime.

The demonstrator examples show you the benefits you can gain by designing a QML-based settings user interface. The settings are structured into groups, their activation states are interdependent, you can pull up file browse dialogs, you can work with sizable and scrollable areas and grid layouts.

File name convention: *_cmn.qml

Description File

This is an optional file. You can use it to write a description of your plugin which is displayed in optiSLang's About Add-Ins dialog box. There is no file name convention, the file name is specified in the configuration file.

Legal Note File

This is an optional file. You can use it to write a legal note of your plugin which is displayed in optiSLang's About Add-Ins dialog box. There is no file name convention, the file name is specified in the configuration file.