Using variables
It is important to distinguish between the standard container object for data being processed (the Entry object) and other generic variables and data types provided to you by JavaScript, as well as those that you create yourself. Your creativity and the capabilities of the scripting language are your only restrictions in terms of what can be placed in scripts inside your Security Directory Integrator solutions. However, when you manipulate data in the context of the data flow, you must be aware of and use the structure of the Entry object.
Entry objects carry attributes, which are themselves the container for data values. Attribute values are themselves objects (java.lang.String, java.util.Date and more complex structures). An attribute value can even be another entry object with its own set of attributes and values. It is the job of SDI to understand how data is stored in the connected system, as well as how to convert these native types to and from the data representation of the system, which is in Java objects.
If you know the class of the attribute value, we can successfully access and interpret this value. For example, if a java.lang.String attribute contains a floating point value that you want to use as a floating point, first manually transform this value, by means of the scripting language, to some numeric data type.
When creating variables or processes not directly related to the data flowing in the integration process and the global objects available, the following principle applies: We can declare and use any variables (objects) enabled by the scripting language. The purpose of these variables is to help you achieve the specific goal associated with the control point in which you script. The variables must serve only as temporary buffers and not attempt to affect the state of the SDI environment.
Parent topic:
Controlling execution with scripting