Chapter 38. Dictionary
Creating a Dictionary |
Using a Dictionary in Graphs |
Dictionary is a data storage object associated with each run of a graph in CloverDX. Its purpose is to provide a simple and type-safe storage of various parameters required by a graph.
It is not limited to storing only input or output parameters but can also be used as a way of sharing data between various components of a single graph.
When a graph is loaded from its XML definition file, the dictionary is initialized based on its definition in the graph specification. Each value is initialized to its default value (if any default value is set) or it must be set by an external source (e.g. Launch Service, etc.).
Between two subsequent runs of any graph, the dictionary is reset to the initial or default settings so that all dictionary runtime changes are destroyed. For this reason, dictionary cannot be used to pass values between different runs of the same graph.
In this chapter, we will describe how a dictionary should be created and how it should be used.