Global variables are used for parametrization. Read about global variables.
Set global variable using JavaScript
importPackage(com.toolsverse.config);
// props is a java.util.HashMap<String, String>
var props = SystemConfig.instance().getProperties();
// you can store strings in props
props.put("unique key", someObject);
Set global variable in a thread-safe container
This is mostly used for parallel loops.
importPackage(com.toolsverse.config);
// props is a java.util.HashMap<String, String>
var props = SystemConfig.instance().getContextProperties();
// you can store strings in props
props.put("unique key", someObject)
Access a previously-stored global variable from JavaScript
importPackage(com.toolsverse.config);
// props is a java.util.HashMap<String, String>
var props = SystemConfig.instance().getProperties();
// use the same key you stored in props.put(...)
var obj = props.get("unique key");
Access a previously-stored global variable from a thread-safe container
This is mostly used for parallel loops.
importPackage(com.toolsverse.config);
// props is a java.util.HashMap<String, String>
var props = SystemConfig.instance().getContextProperties();
// use the same key you stored in props.put(...)
var obj = props.get("unique key");
Access a previously-stored global variable from transformation and Connection parameters
To access the value of the previously stored global variable from the transformation or from the Connection parameters, use {global variable name}
.
Comments
0 comments
Please sign in to leave a comment.