Conditions give you the possibility to make the process flow dependent on the evaluation of certain expressions.
In such an expression, you can compare auto fields, variables, an actual value of a widget or a given constant with each other and decide upon the result, if the process continues one way or the other. Or you might decide to continue the process only if one condition holds and omit the alternative, which in turn results in a process stop at this stage.
If you double click on the shape, it will add a new condition. Alternatively, you can click on the plus icon on the right. By default, an AND condition is created. You can switch between AND and OR (not XOR) conditions using the toggle switch.
|==||value1 is equal to value2 (not checking the data type, only the value)|
|!=||value1 is not equal to value2|
|<||value1 is less value2|
|>||value1 is greater than value2|
|<=||value1 is less or equal to value2|
|>=||value1 is greater or equal to value2|
|isSet||variable has a value|
|isNotSet||variable has not a value|
Let’s see an example:
The process pane contains a condition, that’s executed after the login button got pressed. The condition compares a widget value (value property of widget InputUsername) with the fixed constant value “admin”. This means that the expression evaluates to true if the input value of field username equals “admin”. In this case, the process flow leads to navigate to screen “BusinessScreen”. If the username does not equal “admin”, the user will be navigated to the screen “PrivateScreen”.
Comparing a Widget
|Selecting a widget property for comparison is guided via a three-step dialog. It asks you to select the screen in the first step, then one of the widgets on this screen and finally the property of the widget that you like to use for the comparison.|
Comparing a Constant
|Defining a constant value for comparison is even easier: you specify the data type via a selection in a drop-down box and set the value in the field below.|
Comparing a Variable
|If you want to compare a variable, every existing one in the Data Workbench will be shown within the list. You can switch between the tabs Base Types, Domain Types, Structs, and Collections.|
Comparing an Auto Field
|You can select every generated auto field for comparison as well.|
An iterator is an object that sequentially passes data structures. It respectively returns the following element and determines if there are another elements following.
With the Iterator activity, you iterate over a variable. It has two output ports: each and after.
|each||For every iteration, the following process will be executed.|
|after||After all iterations ended the following process will be executed.|
The Iterator Selection Helper can be accessed by opening the mapping dialog on the right. The mapping dialog can also be opened by double-clicking on the shape.
You can drag and drop the parameter in the drawing area in the middle. By double-clicking on the parameter you can select the collection you want to iterate.
The mapping dialog is aware of its type and offers only collection variables that are defined in the app.
By opening the mapping dialog, you can drag and drop the element on the left and on the right in the middle. By double-clicking on it, you find all parameter/variables that can be mapped listed in a pop-up.