Registry v4.0.0 introduces Dictionaries, which are basically customizable lists that can be used in various contexts, such as Attribute Enumerations as Identifier Validation. The semantics of using a Dictionary varies according to the context in which it is used, see the appropriate documentation for more information.
Dictionaries are created via CO > Configuration > Dictionaries. Entries can be added manually, using a pre-defined list, or by uploading a file of entries.
Dictionary Entries consist of the following components:
Some Pre-Defined Dictionaries are available out of the box:
(Pre-Defined Dictionaries are distributed in the Lib/Dictionary
directory, and use the Dictionary File Format defined below.)
Registry Dictionary Files are JSON documents, consisting of an object with the following members:
description
: An optional string describing the Dictionary.format
: The Dictionary File Format definition used to construct the Dictionary. The current format is "v1
".source
: An optional string describing the source material for constructing the Dictionary.title
: A short title for the Dictionary, suitable for use in Select lists and other similar contexts.version
: A Dictionary-specific version number. Must be a valid JSON number.dictionary
: A JSON array consisting of zero or more objects, each of which may have the following members:code
: An optional code representing the entry.ordr
: An optional integer representing the order of the entry within the Dictionary. Note that, for compatibility with database reserved keywords, there is no e in ordr.value
: The value of the entry.{ "format": "v1", "version": 1, "title": "USDA Egg Grades", "source": "https://www.ams.usda.gov/grades-standards/egg/grade-shields", "description": "Egg categories for consumer grades", "dictionary": [ { "code": "AA", "value": "The freshest and highest quality eggs (AA)", "ordr": 1 }, { "code": "A", "value": "Very high quality eggs (A)", "ordr": 2 }, { "code": "B", "value": "Eggs suitable for liquid and baking purposes (B)", "ordr": 3 }, ] } |
When uploading, a Dictionary File may replace all existing Dictionary Entries (if any), or merge into them. When merging, only the value field is examined – code and ordr are ignored. As an example, if this Dictionary Entry already exists:
and the following entry is uploaded:
on merge, the |