public final class ArrayRegistry extends Object
canonical-json-v1, Section 6: the class (SET, SEQUENCE,
DISPLAY_ORDER) and the sort key of every array position of the lineage document, read from the
x-sqllr-order and x-sqllr-sortKey annotations of the schema, plus the positions of open
content (Section 5, rule 5), where every array is a SEQUENCE.
The positions form a tree: root() is the document, ArrayRegistry.Position.member(String) a member
and ArrayRegistry.Position.element() any element of an array. A position outside the tree is unregistered.
The derivation is the reference's schema_array_registry; the open-content positions are its
OPEN_CONTENT, which the schema does not mark.
| Modifier and Type | Class and Description |
|---|---|
static class |
ArrayRegistry.Order
The registry group
arrayClasses. |
static class |
ArrayRegistry.Position
A position of the document: the root, a member of a position, or any element of an array position.
|
static class |
ArrayRegistry.Registration
The registration of one array position.
|
static class |
ArrayRegistry.SortKey
The sort key of a
SET (Section 6.2). |
| Modifier and Type | Field and Description |
|---|---|
static List<String> |
MODULE_ARRAYS
The module collections whose element schemas are not defined yet (canonical-json-v1, Section 6.3).
|
| Modifier and Type | Method and Description |
|---|---|
static ArrayRegistry |
fromSchema(Object schema)
Derives the registry from a lineage document schema (a parsed JSON value).
|
SortedSet<String> |
openContent()
Every open-content position other than
extensions members, as a display path. |
SortedMap<String,ArrayRegistry.Registration> |
registrations()
Every registered array position, as a display path (
$.endpoints[].name.segments). |
ArrayRegistry.Position |
root()
The position of the document root.
|
static ArrayRegistry |
standard()
The registry of the schema shipped with this library.
|
public static final List<String> MODULE_ARRAYS
public ArrayRegistry.Position root()
public SortedMap<String,ArrayRegistry.Registration> registrations()
$.endpoints[].name.segments).public SortedSet<String> openContent()
extensions members, as a display path.public static ArrayRegistry standard()
public static ArrayRegistry fromSchema(Object schema)
IllegalStateException - when an array position has no class, two classes, or an unknown sort key