public final class RelationBinding extends Object
RelationKind.TABLE binding whose
qualifiedName is the bare table name; later slices fill
server/database/schema and add CTE/SUBQUERY kinds.
Slice 14 added RelationKind.OUTER_REFERENCE to model an
inner statement's reference to an enclosing-scope alias. Slice 15
extends OUTER_REFERENCE bindings to carry an outerKind
specifying what the enclosing-scope relation is actually bound to
(TABLE / CTE / SUBQUERY); the projector dispatches through that
resolved kind to BFS the outer body for CTE / SUBQUERY correlations.
Constructor invariants:
kind == OUTER_REFERENCE —
OUTER_REFERENCE callers MUST use the 3-arg form so the
resolved outerKind is always declared explicitly.kind != OUTER_REFERENCE.
The outerKind parameter must be one of the allow-list
{TABLE, CTE, SUBQUERY}; UNION / UNKNOWN /
OUTER_REFERENCE / null all throw.| Constructor and Description |
|---|
RelationBinding(RelationKind kind,
String qualifiedName) |
RelationBinding(RelationKind kind,
String qualifiedName,
RelationKind outerKind) |
| Modifier and Type | Method and Description |
|---|---|
RelationKind |
getKind() |
RelationKind |
getOuterKind()
For OUTER_REFERENCE bindings, the underlying kind that the
enclosing-scope relation resolves to (TABLE / CTE / SUBQUERY).
|
String |
getQualifiedName() |
public RelationBinding(RelationKind kind, String qualifiedName)
public RelationBinding(RelationKind kind, String qualifiedName, RelationKind outerKind)
public RelationKind getKind()
public String getQualifiedName()
public RelationKind getOuterKind()
null for non-OUTER_REFERENCE bindings.