Class JoinScope
Object
gudusoft.gsqlparser.resolver2.scope.AbstractScope
gudusoft.gsqlparser.resolver2.scope.ListBasedScope
gudusoft.gsqlparser.resolver2.scope.JoinScope
- All Implemented Interfaces:
IScope
Scope for JOIN operations.
Handles nullable semantics for different JOIN types.
JOIN semantics:
- INNER JOIN: both sides non-nullable
- LEFT JOIN: left non-nullable, right nullable
- RIGHT JOIN: left nullable, right non-nullable
- FULL JOIN: both sides nullable
- CROSS JOIN: both sides non-nullable
Example:
FROM users u
LEFT JOIN orders o ON u.id = o.user_id
^^^^^ ^^^^^^
leftNamespace rightNamespace (nullable)
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classNullable semantics for a JOIN operation -
Field Summary
Fields inherited from class gudusoft.gsqlparser.resolver2.scope.ListBasedScope
childrenFields inherited from class gudusoft.gsqlparser.resolver2.scope.AbstractScope
node, parent, scopeType -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic JoinScope.NullableSemanticsgetNullableSemantics(TJoinExpr joinExpr) Determine nullable semantics based on JOIN typebooleanbooleanvoidsetLeft(INamespace namespace, String alias, boolean nullable) Set the left side of the JOINvoidsetRight(INamespace namespace, String alias, boolean nullable) Set the right side of the JOINtoString()Methods inherited from class gudusoft.gsqlparser.resolver2.scope.ListBasedScope
addChild, getChildren, getVisibleNamespaces, resolve, resolveInNamespace, resolveTableMethods inherited from class gudusoft.gsqlparser.resolver2.scope.AbstractScope
fullyQualify, getNode, getParent, getScopeType, isWithin
-
Constructor Details
-
JoinScope
-
-
Method Details
-
setLeft
Set the left side of the JOIN -
setRight
Set the right side of the JOIN -
getNullableSemantics
Determine nullable semantics based on JOIN type -
getJoinExpr
-
getLeftNamespace
-
getRightNamespace
-
isLeftNullable
-
isRightNullable
-
toString
- Overrides:
toStringin classListBasedScope
-