18 using System.Collections.Generic;
21 namespace Deveel.Data.Sql.Parser {
34 VisitIntegerLiteral((IntegerLiteralNode) node);
36 VisitNumberLiteral((NumberLiteralNode) node);
38 VisitStringLiteral((StringLiteralNode) node);
40 VisitDataType((DataTypeNode) node);
42 VisitExpression((IExpressionNode) node);
44 VisitStatement((IStatementNode) node);
46 ((ISqlVisitableNode) node).Accept(
this);
67 VisitConstantExpression((SqlConstantExpressionNode) node);
69 VisitReferenceExpression((SqlReferenceExpressionNode) node);
71 VisitVariableRefExpression((SqlVariableRefExpressionNode) node);
73 VisitBetweenExpression((SqlBetweenExpressionNode) node);
75 VisitCaseExpression((SqlCaseExpressionNode) node);
77 VisitFunctionCall((SqlFunctionCallExpressionNode) node);
79 VisitTupleExpression((SqlExpressionTupleNode) node);
81 VisitBinaryExpression((SqlBinaryExpressionNode) node);
83 VisitUnaryExpression((SqlUnaryExpressionNode) node);
85 VisitQueryExpression((SqlQueryExpressionNode) node);
87 throw new InvalidOperationException(String.Format(
"The expression node of type '{0}' is invalid.", node.GetType()));
92 foreach (var node
in nodes) {
105 VisitNodeList(exps.Cast<
ISqlNode>());
138 VisitCreateTable((CreateTableNode) node);
140 VisitCreateView((CreateViewNode) node);
142 VisitCreateTrigger((CreateTriggerNode) node);
144 VisitSelect((SelectStatementNode) node);
146 VisitUpdate((UpdateStatementNode) node);
148 VisitInsert((InsertStatementNode) node);
155 VisitExpression(exp);
170 VisitTableColumns(node.
Columns);
180 foreach (var action
in node.
Actions) {
181 VisitAlterTableAction(action);
190 foreach (var constraint
in constraints) {
191 VisitTableConstraint(constraint);
SqlQueryExpressionNode QueryExpression
virtual void VisitBetweenExpression(SqlBetweenExpressionNode node)
virtual void VisitNodeList(IEnumerable< ISqlNode > nodes)
An interface that allows implementations of the visitor pattern on SQL compiled nodes.
virtual void VisitNumberLiteral(NumberLiteralNode node)
Defines the contract for nodes in an AST model for a SQL grammar analysis and parsing.
virtual void VisitCreateTable(CreateTableNode node)
virtual void VisitReferenceExpression(SqlReferenceExpressionNode node)
virtual void VisitSelect(SelectStatementNode node)
IEnumerable< IAlterActionNode > Actions
virtual void VisitFunctionCall(SqlFunctionCallExpressionNode node)
virtual void VisitUpdate(UpdateStatementNode node)
An expression that encapsulates a unary operator for a given operand.
An SQL BETWEEN expression node that evaluates to true if the Expression given is between MinValue (in...
virtual void VisitTableConstraint(TableConstraintNode arg)
virtual void VisitTableConstraints(IEnumerable< TableConstraintNode > constraints)
Handles a numeric literal value, belonging to a wider group than integer numbers, spanning from real ...
An expression containing a set of other expressions.
virtual void VisitConstantExpression(SqlConstantExpressionNode node)
IExpressionNode[] ProcedureArguments
IEnumerable< TableColumnNode > Columns
virtual void VisitCreateTrigger(CreateTriggerNode node)
The root node of an expression used to select a set of items from a set of sources defined...
An implementation of ISqlNode that accepts visits from a ISqlNodeVisitor
An expression node that references an object within the database context (such as a table...
QueryUpdateNode QueryUpdate
SimpleUpdateNode SimpleUpdate
A node containing a constant literal string passed within an SQL command.
virtual void VisitIntegerLiteral(IntegerLiteralNode node)
virtual void VisitTableColumns(IEnumerable< TableColumnNode > columnNodes)
virtual void Visit(ISqlNode node)
Visits the given SQL node.
virtual void VisitSimpleUpdate(SimpleUpdateNode node)
virtual void VisitUnaryExpression(SqlUnaryExpressionNode node)
virtual void VisitQueryUpdate(QueryUpdateNode node)
virtual void VisitCaseExpression(SqlCaseExpressionNode node)
virtual void VisitExpression(IExpressionNode node)
References a variable within a SQL execution context.
CreateTableNode CreateTable
virtual void VisitBinaryExpression(SqlBinaryExpressionNode node)
IEnumerable< TableConstraintNode > Constraints
virtual void VisitTupleExpression(SqlExpressionTupleNode node)
virtual void VisitStringLiteral(StringLiteralNode node)
virtual void VisitVariableRefExpression(SqlVariableRefExpressionNode node)
virtual void VisitAlterTableAction(IAlterActionNode action)
virtual void VisitQueryExpression(SqlQueryExpressionNode node)
virtual void VisitDataType(DataTypeNode node)
An node that represents a constant value set within a context of an SQL command.
Describes the information of a data type as found in a SQL string.
virtual void VisitStatement(IStatementNode node)
virtual void VisitAlterTable(AlterTableNode node)
virtual void VisitCreateView(CreateViewNode node)
This interface acts like a marker that indicates if a ISqlNode represents a SQL expression.
Represents an expression that evaluates between two other expressions.
IEnumerable< IExpressionNode > Expressions
Gets a read-only list of expression that are contained within this tuple.
A node in a SQL command tree that is used to request a function.
virtual void VisitInsert(InsertStatementNode node)
Encapsulates a number that is any falling in the group of integers.
An SQL node describing an in-line CASE conditional expression.
The default implementation of a ISqlNodeVisitor that implements the visitor as a protected accessor...