Model settings are also called Model parameters.
The model parameters can be transferred at the start of a process flow: they will be used as ordinary variables in the program code. Model parameters have to be captured in the model in the Project Explorer: Context menu of the model → Properties → Model Settings.
Greyed-out parameters are inherited from the platform (ex.
company) or from referenced models. They cannot be changed at this location, but they can be accessed within the model.
runID- is the run number for each start of the process flow: it is an integer. This parameter may only be read but not changed.
company- is the company for which a process flow is started: it is an integer. This value should not be changed in the current Jabatix status.
New parameters are created by pressing the Add button:
The name is mandatory.
- The label is displayed in the user interface when the parameter is requested
- The description is only for documentation purposes
- The possible data types are stored in the list box, ranging from Boolean, several integer types and real types, to string. The value ranges for the types are defined in the section Datatypes, variables, operators
- If a parameter consists of only one variable, the parameter type is single; for multiple variables, it is an ArrayList; a function can also be stored as a default value. In this case, the parameter type is Expression
- The default value is also shown in the user interface. It can be defined as a constant (single or multi), or as a function with a return value that is the default value (expression); the functions of the same model and of all the referenced models can be used. Java functions, for example the functions (methods) of the classes String, Integer and BigDecimal, can also be used
- The permitted values can be defined as an ArrayList. In this case, the elements in this list can also be determined by function calls. The same functions as those allowed for the default value field are permitted; alternatively, a Business Object can deliver the list via the button BO selection; the BO, its attribute that delivers the permitted values, and the values displayed in theuser interface can be selected
- The BO can be restricted by using a Where clause
- Only parameters that have configured the adjustable checkbox can be entered from the User Interface at the start
- The entries of the model parameters with the property encrypted are only shown as periods (passwords)
Model parameters can be deleted by Remove or put in a sensible order using Move Up/Down
They can be accessed by ModelParameters.<name> in the Cantor script. For example, the model parameter
runId can be accessed as follows:
Dim currentRunId As Integer = ModelParameters.runId
Model parameters in process flows
Example with Model Setting/Model Parameter, in-memory data transformation, and report
Functionality: provide a report that lists numbers and their equivalent names (as strings) → 0 to 9.
Use a script associated with a BO field and an In-Memory script, to populate the list: