| Package | Description |
|---|---|
| gudusoft.gsqlparser.ir.semantic |
Semantic analysis results, diagnostics, and supporting implementation APIs.
|
| gudusoft.gsqlparser.ir.semantic.joinanalysis |
Immutable join-analysis facts exposed by Semantic IR.
|
| Modifier and Type | Method and Description |
|---|---|
SourceSpan |
OutputColumn.getExpressionSpan()
Source span of the projection expression (US-021a), half-open per
SourceSpan. |
SourceSpan |
ColumnRef.getSourceSpan()
Optional source-text span of this column reference (join-analysis
slice 164).
|
SourceSpan |
StatementGraph.getSourceSpan()
Optional block-level source span (slice 179, R5) covering this
statement's own text, or
null when not set. |
SourceSpan |
RelationSource.getSourceSpan()
Optional source-text span of this relation reference (join-analysis
slice 164).
|
SourceSpan |
RelatedLocation.getSpan() |
SourceSpan |
Diagnostic.getSpan() |
SourceSpan |
LineageRef.getSpan()
Optional source span of this endpoint (US-021a).
|
static SourceSpan |
SourceSpan.of(long startLine,
long startColumn,
long endLine,
long endColumn)
Construct an explicit half-open source span.
|
static SourceSpan |
SourceSpan.of(TParseTreeNode node)
Derive a span from the AST node's start and end tokens.
|
static SourceSpan |
SourceSpan.of(TSourceToken start,
TSourceToken end)
Derive a span from explicit start / end tokens.
|
| Modifier and Type | Method and Description |
|---|---|
static Diagnostic |
Diagnostic.errorWithSpan(DiagnosticCode code,
String message,
SourceSpan span)
Construct an
ERROR-severity diagnostic
with an explicit (already-computed) source span. |
static RelatedLocation |
RelatedLocation.of(String role,
String message,
SourceSpan span) |
Optional<String> |
StatementSourceView.slice(SourceSpan span)
Slice a global half-open span from the original SQL text.
|
Diagnostic.Builder |
Diagnostic.Builder.span(SourceSpan value) |
static StatementGraph |
StatementGraph.unanalyzed(String name,
Diagnostic reason,
SourceSpan span)
Build the degrade placeholder for a nested block that could not be
analyzed.
|
static Diagnostic |
Diagnostic.warnWithSpan(DiagnosticCode code,
String message,
SourceSpan span)
Construct a
WARN-severity diagnostic with an
explicit (already-computed) source span — the WARN counterpart of
Diagnostic.errorWithSpan(gudusoft.gsqlparser.ir.semantic.DiagnosticCode, java.lang.String, gudusoft.gsqlparser.ir.semantic.SourceSpan). |
OutputColumn |
OutputColumn.withExpression(String expressionText,
SourceSpan expressionSpan)
Copy of this output column with the projection-expression provenance
attached (US-021a).
|
StatementGraph |
StatementGraph.withSourceSpan(SourceSpan newSourceSpan)
Return a copy of this statement with its block-level
StatementGraph.sourceSpan replaced (slice 179, R5). |
Diagnostic |
Diagnostic.withSpan(SourceSpan newSpan)
Return an immutable copy with a new primary span.
|
LineageRef |
LineageRef.withSpan(SourceSpan span)
Copy of this ref with the optional endpoint source span attached
(US-021a) — for a STATEMENT_OUTPUT endpoint, the projection
expression's span; for a TABLE_COLUMN endpoint, the span of the
column reference it was resolved from.
|
| Constructor and Description |
|---|
ColumnRef(String relationAlias,
String columnName,
StructuredColumnPath structuredPath,
SourceSpan sourceSpan)
Slice 164 — adds the optional source span.
|
ColumnRef(String relationAlias,
String columnName,
StructuredColumnPath structuredPath,
SourceSpan sourceSpan,
ColumnResolution resolution)
Full constructor (join-analysis slice 165).
|
OutputColumn(String name,
boolean derived,
boolean aggregate,
List<ColumnRef> sources,
WindowSpec windowSpec,
String expressionText,
SourceSpan expressionSpan)
Full constructor (US-021a).
|
RelatedLocation(String role,
String message,
SourceSpan span) |
RelationSource(String alias,
RelationBinding binding,
SourceSpan sourceSpan) |
RelationSource(String alias,
RelationBinding binding,
SourceSpan sourceSpan,
int instanceId)
Full constructor (join-analysis slice 179).
|
StatementGraph(String name,
String kind,
List<RelationSource> relations,
List<OutputColumn> outputColumns,
List<OutputColumn> returningColumns,
List<ColumnRef> filterColumnRefs,
List<ColumnRef> joinColumnRefs,
List<ColumnRef> groupByColumnRefs,
List<ColumnRef> havingColumnRefs,
List<ColumnRef> orderByColumnRefs,
List<ColumnRef> distinctOnColumnRefs,
List<ColumnRef> qualifyColumnRefs,
List<GroupingElement> groupingElements,
List<ColumnRef> pivotColumnRefs,
boolean distinct,
SetOperator setOperator,
RowLimit rowLimit,
TargetRelation target,
JoinAnalysisFacts joinAnalysisFacts,
SourceSpan sourceSpan)
Slice 179 (R5) primary constructor — adds the optional block-level
SourceSpan covering this statement's own source text. |
| Modifier and Type | Method and Description |
|---|---|
SourceSpan |
JoinEntity.getSourceSpan()
Optional; null when the parser cannot anchor the join clause.
|
SourceSpan |
Predicate.getSourceSpan()
Optional; null when the parser cannot anchor this predicate.
|
SourceSpan |
PredicateOperand.getSourceSpan()
Optional; null when the parser cannot anchor this operand.
|
SourceSpan |
QueryBlockScope.getSourceSpan()
Optional; null when the parser cannot anchor the block.
|
| Modifier and Type | Method and Description |
|---|---|
static PredicateOperand |
PredicateOperand.call(String text,
SourceSpan span) |
static PredicateOperand |
PredicateOperand.column(ColumnRef column,
SourceSpan span) |
static PredicateOperand |
PredicateOperand.complex(String text,
SourceSpan span) |
static PredicateOperand |
PredicateOperand.literal(String text,
SourceSpan span) |
| Constructor and Description |
|---|
JoinEntity(SemanticJoinType joinType,
JoinEndpoint leftEndpoint,
JoinEndpoint rightEndpoint,
int order,
JoinSourceSyntax sourceSyntax,
boolean naturalFlag,
List<String> usingColumns,
List<Predicate> conditions,
SourceSpan sourceSpan,
String conditionText)
Original 10-arg constructor (non-lateral).
|
JoinEntity(SemanticJoinType joinType,
JoinEndpoint leftEndpoint,
JoinEndpoint rightEndpoint,
int order,
JoinSourceSyntax sourceSyntax,
boolean naturalFlag,
List<String> usingColumns,
List<Predicate> conditions,
SourceSpan sourceSpan,
String conditionText,
boolean lateralFlag)
Full constructor.
|
Predicate(PredicateKind kind,
String operator,
PredicateOperand leftOperand,
PredicateOperand rightOperand,
SourceSpan sourceSpan) |
QueryBlockScope(int statementIndex,
Integer parentStatementIndex,
ScopeKind scopeKind,
String name,
SourceSpan sourceSpan) |