Project variables serve to customize the behavior of your transformation project. In the project settings you can define variables that can be used in parameters for transformation functions or scripts. Variables defined there will be saved with the project, but can also be overridden by setting specific environment variables or providing Java system properties.
Go to Window→Settings and then to Project→Variables to define project variables from within halestudio. Any variable you add here is stored in the project when you next save it.
When looking up a project variable, hale first looks for a
corresponding Java system property with the prefix
this means to override the variable with the name
, you can specify a system property named
If no system property is found, hale looks for a corresponding
environment variable. In that case the expected prefix is
. Thus to override the variable with the name
, you can specify an environment variable named
The variable value stored in the project is used when neither a system property nor an environment variable are defined. If the variable is also not defined in the project, it is not resolved.
Most transformation functions support variable replacement in their parameters. If you want to have a variable value inserted into a parameter, specify it with the following notation:
See the image below for an example using a variable in the Assign function:
Specific support for using project variables is also provided in Groovy script based functions. Please take a look at the respective function documentation on how to use project variables there.