Declaring and passing variables
Variables capture the business data that is passed from
step to step in a process.
The variables are local to a process or service. You cannot reference a variable from another process or service. Variables contain the values or references to business data. To propagate the business data values and references, you must properly declare the variables and pass them to the linked processes, services, and message events.
The general procedure for passing variables is:
- Declare variables at the process level.
- For each linked process and service, declare variables and business objects to receive the values of the variables of the main process.
- Pass those variables as inputs to the linked processes and services that require them for their implementation.
- Pass the variables from the linked processes and services back up to the main process as outputs when you want the main process to be aware of changes made to the variables in the linked processes or services.
When passing variables from a process to a linked process, their types should be compatible. For example, a string variable in a process can only be passed to a linked process if this linked process has a string variable declared as an input variable.