You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by zh...@apache.org on 2020/10/26 13:10:05 UTC
[shardingsphere] branch master updated: Add SQLTypeVisitor and
SQLOperationVisitor (#7923)
This is an automated email from the ASF dual-hosted git repository.
zhangyonglun pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/shardingsphere.git
The following commit(s) were added to refs/heads/master by this push:
new a832d65 Add SQLTypeVisitor and SQLOperationVisitor (#7923)
a832d65 is described below
commit a832d65ff2b8c09524bf5a0735eed3f980a86aac
Author: Liang Zhang <te...@163.com>
AuthorDate: Mon Oct 26 21:05:26 2020 +0800
Add SQLTypeVisitor and SQLOperationVisitor (#7923)
* Update release guide for diff
* Add SQLTypeVisitor and SQLOperationVisitor
---
.../parser/sql/parser/ShardingSphereParser.java | 2 +-
.../parser/sql/visitor/ShardingSphereVisitor.java | 2 +-
.../statement/rdl/DataSourceConnectionSegment.java | 2 +-
.../rdl/parser/statement/rdl/TableRuleSegment.java | 2 +-
.../sql/parser/mysql/parser/MySQLParser.java | 2 +-
.../visitor/MySQLSQLVisitorFacadeFactory.java | 8 +++---
.../format/facade/MySQLFormatSQLVisitorFacade.java | 28 ++++++++++----------
.../format/impl/MySQLDALFormatSQLVisitor.java | 5 ++--
.../format/impl/MySQLDCLFormatSQLVisitor.java | 5 ++--
.../format/impl/MySQLDDLFormatSQLVisitor.java | 5 ++--
.../format/impl/MySQLDMLFormatSQLVisitor.java | 5 ++--
.../format/impl/MySQLRLFormatSQLVisitor.java | 5 ++--
.../format/impl/MySQLTCLFormatSQLVisitor.java | 5 ++--
.../facade/MySQLStatementSQLVisitorFacade.java | 28 ++++++++++----------
.../impl/MySQLDALStatementSQLVisitor.java | 19 +++++++-------
.../impl/MySQLDCLStatementSQLVisitor.java | 7 ++---
.../impl/MySQLDDLStatementSQLVisitor.java | 7 ++---
.../impl/MySQLDMLStatementSQLVisitor.java | 7 ++---
.../statement/impl/MySQLRLStatementSQLVisitor.java | 7 ++---
.../statement/impl/MySQLStatementSQLVisitor.java | 2 +-
.../impl/MySQLTCLStatementSQLVisitor.java | 7 ++---
.../sql/parser/oracle/parser/OracleParser.java | 2 +-
.../visitor/OracleSQLVisitorFacadeFactory.java | 8 +++---
.../facade/OracleFormatSQLVisitorFacade.java | 28 ++++++++++----------
.../facade/OracleStatementSQLVisitorFacade.java | 28 ++++++++++----------
.../impl/OracleDALStatementSQLVisitor.java | 5 ++--
.../impl/OracleDCLStatementSQLVisitor.java | 7 ++---
.../impl/OracleDDLStatementSQLVisitor.java | 7 ++---
.../impl/OracleDMLStatementSQLVisitor.java | 7 ++---
.../statement/impl/OracleStatementSQLVisitor.java | 2 +-
.../impl/OracleTCLStatementSQLVisitor.java | 7 ++---
.../parser/postgresql/parser/PostgreSQLParser.java | 2 +-
.../visitor/PostgreSQLSQLVisitorFacadeFactory.java | 8 +++---
.../facade/PostgreSQLFormatSQLVisitorFacade.java | 28 ++++++++++----------
.../PostgreSQLStatementSQLVisitorFacade.java | 28 ++++++++++----------
.../impl/PostgreSQLDALStatementSQLVisitor.java | 7 ++---
.../impl/PostgreSQLDCLStatementSQLVisitor.java | 7 ++---
.../impl/PostgreSQLDDLStatementSQLVisitor.java | 7 ++---
.../impl/PostgreSQLDMLStatementSQLVisitor.java | 7 ++---
.../impl/PostgreSQLStatementSQLVisitor.java | 2 +-
.../impl/PostgreSQLTCLStatementSQLVisitor.java | 7 ++---
.../sql/parser/sql92/parser/SQL92Parser.java | 2 +-
.../visitor/SQL92SQLVisitorFacadeFactory.java | 8 +++---
.../format/facade/SQL92FormatSQLVisitorFacade.java | 28 ++++++++++----------
.../facade/SQL92StatementSQLVisitorFacade.java | 28 ++++++++++----------
.../impl/SQL92DALStatementSQLVisitor.java | 5 ++--
.../impl/SQL92DCLStatementSQLVisitor.java | 7 ++---
.../impl/SQL92DDLStatementSQLVisitor.java | 7 ++---
.../impl/SQL92DMLStatementSQLVisitor.java | 7 ++---
.../statement/impl/SQL92StatementSQLVisitor.java | 2 +-
.../impl/SQL92TCLStatementSQLVisitor.java | 7 ++---
.../parser/sqlserver/parser/SQLServerParser.java | 2 +-
.../visitor/SQLServerSQLVisitorFacadeFactory.java | 8 +++---
.../facade/SQLServerFormatSQLVisitorFacade.java | 28 ++++++++++----------
.../facade/SQLServerStatementSQLVisitorFacade.java | 28 ++++++++++----------
.../impl/SQLServerDALStatementSQLVisitor.java | 5 ++--
.../impl/SQLServerDCLStatementSQLVisitor.java | 7 ++---
.../impl/SQLServerDDLStatementSQLVisitor.java | 7 ++---
.../impl/SQLServerDMLStatementSQLVisitor.java | 7 ++---
.../impl/SQLServerStatementSQLVisitor.java | 2 +-
.../impl/SQLServerTCLStatementSQLVisitor.java | 7 ++---
.../sql/parser/core/ParseASTNode.java | 2 +-
.../sql/parser/api/parser/SQLParser.java | 2 +-
.../api/visitor/{statement => }/ASTNode.java | 2 +-
.../api/visitor/SQLVisitorFacadeFactory.java | 8 +++---
.../visitor/format/impl/TCLFormatSQLVisitor.java | 26 -------------------
.../SQLOperationVisitor.java} | 6 ++---
.../format/SQLFormatVisitor.java} | 8 +++---
.../format/SQLFormatVisitorFacade.java} | 30 +++++++++++-----------
.../statement/SQLStatementVisitor.java} | 8 +++---
.../statement/SQLStatementVisitorFacade.java} | 30 +++++++++++-----------
.../statement/impl/DALStatementSQLVisitor.java | 26 -------------------
.../statement/impl/DCLStatementSQLVisitor.java | 26 -------------------
.../statement/impl/DDLStatementSQLVisitor.java | 26 -------------------
.../statement/impl/DMLStatementSQLVisitor.java | 26 -------------------
.../statement/impl/RLStatementSQLVisitor.java | 26 -------------------
.../statement/impl/TCLStatementSQLVisitor.java | 26 -------------------
.../SQLTypeVisitor.java} | 6 ++---
.../impl/DALSQLVisitor.java} | 8 +++---
.../impl/DCLSQLVisitor.java} | 8 +++---
.../impl/DDLSQLVisitor.java} | 8 +++---
.../impl/DMLSQLVisitor.java} | 8 +++---
.../ASTNode.java => type/impl/RLSQLVisitor.java} | 8 +++---
.../impl/TCLSQLVisitor.java} | 8 +++---
.../sql/parser/sql/common/segment/SQLSegment.java | 2 +-
.../parser/sql/common/statement/SQLStatement.java | 2 +-
.../sql/parser/sql/common/value/ValueASTNode.java | 2 +-
87 files changed, 378 insertions(+), 526 deletions(-)
diff --git a/shardingsphere-rdl-parser/shardingsphere-rdl-parser-sql/src/main/java/org/apache/shardingsphere/rdl/parser/sql/parser/ShardingSphereParser.java b/shardingsphere-rdl-parser/shardingsphere-rdl-parser-sql/src/main/java/org/apache/shardingsphere/rdl/parser/sql/parser/ShardingSphereParser.java
index b303201..4b16ca1 100644
--- a/shardingsphere-rdl-parser/shardingsphere-rdl-parser-sql/src/main/java/org/apache/shardingsphere/rdl/parser/sql/parser/ShardingSphereParser.java
+++ b/shardingsphere-rdl-parser/shardingsphere-rdl-parser-sql/src/main/java/org/apache/shardingsphere/rdl/parser/sql/parser/ShardingSphereParser.java
@@ -19,7 +19,7 @@ package org.apache.shardingsphere.rdl.parser.sql.parser;
import org.antlr.v4.runtime.TokenStream;
import org.apache.shardingsphere.rdl.parser.autogen.ShardingSphereStatementParser;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
import org.apache.shardingsphere.sql.parser.api.parser.SQLParser;
import org.apache.shardingsphere.sql.parser.core.ParseASTNode;
diff --git a/shardingsphere-rdl-parser/shardingsphere-rdl-parser-sql/src/main/java/org/apache/shardingsphere/rdl/parser/sql/visitor/ShardingSphereVisitor.java b/shardingsphere-rdl-parser/shardingsphere-rdl-parser-sql/src/main/java/org/apache/shardingsphere/rdl/parser/sql/visitor/ShardingSphereVisitor.java
index a06de48..e396a54 100644
--- a/shardingsphere-rdl-parser/shardingsphere-rdl-parser-sql/src/main/java/org/apache/shardingsphere/rdl/parser/sql/visitor/ShardingSphereVisitor.java
+++ b/shardingsphere-rdl-parser/shardingsphere-rdl-parser-sql/src/main/java/org/apache/shardingsphere/rdl/parser/sql/visitor/ShardingSphereVisitor.java
@@ -31,7 +31,7 @@ import org.apache.shardingsphere.rdl.parser.statement.rdl.CreateDataSourcesState
import org.apache.shardingsphere.rdl.parser.statement.rdl.CreateShardingRuleStatement;
import org.apache.shardingsphere.rdl.parser.statement.rdl.DataSourceConnectionSegment;
import org.apache.shardingsphere.rdl.parser.statement.rdl.TableRuleSegment;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
import org.apache.shardingsphere.sql.parser.sql.common.value.collection.CollectionValue;
import java.util.Collection;
diff --git a/shardingsphere-rdl-parser/shardingsphere-rdl-parser-statement/src/main/java/org/apache/shardingsphere/rdl/parser/statement/rdl/DataSourceConnectionSegment.java b/shardingsphere-rdl-parser/shardingsphere-rdl-parser-statement/src/main/java/org/apache/shardingsphere/rdl/parser/statement/rdl/DataSourceConnectionSegment.java
index a4eea7a..46b56d8 100644
--- a/shardingsphere-rdl-parser/shardingsphere-rdl-parser-statement/src/main/java/org/apache/shardingsphere/rdl/parser/statement/rdl/DataSourceConnectionSegment.java
+++ b/shardingsphere-rdl-parser/shardingsphere-rdl-parser-statement/src/main/java/org/apache/shardingsphere/rdl/parser/statement/rdl/DataSourceConnectionSegment.java
@@ -19,7 +19,7 @@ package org.apache.shardingsphere.rdl.parser.statement.rdl;
import lombok.Getter;
import lombok.Setter;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
/**
* Data source connection segment.
diff --git a/shardingsphere-rdl-parser/shardingsphere-rdl-parser-statement/src/main/java/org/apache/shardingsphere/rdl/parser/statement/rdl/TableRuleSegment.java b/shardingsphere-rdl-parser/shardingsphere-rdl-parser-statement/src/main/java/org/apache/shardingsphere/rdl/parser/statement/rdl/TableRuleSegment.java
index 8c460cc..836e384 100644
--- a/shardingsphere-rdl-parser/shardingsphere-rdl-parser-statement/src/main/java/org/apache/shardingsphere/rdl/parser/statement/rdl/TableRuleSegment.java
+++ b/shardingsphere-rdl-parser/shardingsphere-rdl-parser-statement/src/main/java/org/apache/shardingsphere/rdl/parser/statement/rdl/TableRuleSegment.java
@@ -19,7 +19,7 @@ package org.apache.shardingsphere.rdl.parser.statement.rdl;
import lombok.Getter;
import lombok.Setter;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
import java.util.Collection;
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/parser/MySQLParser.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/parser/MySQLParser.java
index fac8f5a..b3b8f63 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/parser/MySQLParser.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/parser/MySQLParser.java
@@ -18,7 +18,7 @@
package org.apache.shardingsphere.sql.parser.mysql.parser;
import org.antlr.v4.runtime.TokenStream;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
import org.apache.shardingsphere.sql.parser.api.parser.SQLParser;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser;
import org.apache.shardingsphere.sql.parser.core.ParseASTNode;
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/MySQLSQLVisitorFacadeFactory.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/MySQLSQLVisitorFacadeFactory.java
index 3c7268f..706cc39 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/MySQLSQLVisitorFacadeFactory.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/MySQLSQLVisitorFacadeFactory.java
@@ -18,8 +18,8 @@
package org.apache.shardingsphere.sql.parser.mysql.visitor;
import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitorFacadeFactory;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.facade.FormatSQLVisitorFacade;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.facade.StatementSQLVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.format.SQLFormatVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitorFacade;
import org.apache.shardingsphere.sql.parser.mysql.visitor.format.facade.MySQLFormatSQLVisitorFacade;
import org.apache.shardingsphere.sql.parser.mysql.visitor.statement.facade.MySQLStatementSQLVisitorFacade;
@@ -29,12 +29,12 @@ import org.apache.shardingsphere.sql.parser.mysql.visitor.statement.facade.MySQL
public final class MySQLSQLVisitorFacadeFactory implements SQLVisitorFacadeFactory {
@Override
- public Class<? extends StatementSQLVisitorFacade> getStatementSQLVisitorFacadeClass() {
+ public Class<? extends SQLStatementVisitorFacade> getStatementSQLVisitorFacadeClass() {
return MySQLStatementSQLVisitorFacade.class;
}
@Override
- public Class<? extends FormatSQLVisitorFacade> getFormatSQLVisitorFacadeClass() {
+ public Class<? extends SQLFormatVisitorFacade> getFormatSQLVisitorFacadeClass() {
return MySQLFormatSQLVisitorFacade.class;
}
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/facade/MySQLFormatSQLVisitorFacade.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/facade/MySQLFormatSQLVisitorFacade.java
index bb8b7bd..95eb90c 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/facade/MySQLFormatSQLVisitorFacade.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/facade/MySQLFormatSQLVisitorFacade.java
@@ -17,13 +17,13 @@
package org.apache.shardingsphere.sql.parser.mysql.visitor.format.facade;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.facade.FormatSQLVisitorFacade;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DALFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DCLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DDLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DMLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.RLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.TCLFormatSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.format.SQLFormatVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DALSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DCLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DDLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DMLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.RLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.TCLSQLVisitor;
import org.apache.shardingsphere.sql.parser.mysql.visitor.format.impl.MySQLDALFormatSQLVisitor;
import org.apache.shardingsphere.sql.parser.mysql.visitor.format.impl.MySQLDCLFormatSQLVisitor;
import org.apache.shardingsphere.sql.parser.mysql.visitor.format.impl.MySQLDDLFormatSQLVisitor;
@@ -34,35 +34,35 @@ import org.apache.shardingsphere.sql.parser.mysql.visitor.format.impl.MySQLTCLFo
/**
* Format SQL Visitor facade for MySQL.
*/
-public final class MySQLFormatSQLVisitorFacade implements FormatSQLVisitorFacade {
+public final class MySQLFormatSQLVisitorFacade implements SQLFormatVisitorFacade {
@Override
- public Class<? extends DMLFormatSQLVisitor> getDMLVisitorClass() {
+ public Class<? extends DMLSQLVisitor> getDMLVisitorClass() {
return MySQLDMLFormatSQLVisitor.class;
}
@Override
- public Class<? extends DDLFormatSQLVisitor> getDDLVisitorClass() {
+ public Class<? extends DDLSQLVisitor> getDDLVisitorClass() {
return MySQLDDLFormatSQLVisitor.class;
}
@Override
- public Class<? extends TCLFormatSQLVisitor> getTCLVisitorClass() {
+ public Class<? extends TCLSQLVisitor> getTCLVisitorClass() {
return MySQLTCLFormatSQLVisitor.class;
}
@Override
- public Class<? extends DCLFormatSQLVisitor> getDCLVisitorClass() {
+ public Class<? extends DCLSQLVisitor> getDCLVisitorClass() {
return MySQLDCLFormatSQLVisitor.class;
}
@Override
- public Class<? extends DALFormatSQLVisitor> getDALVisitorClass() {
+ public Class<? extends DALSQLVisitor> getDALVisitorClass() {
return MySQLDALFormatSQLVisitor.class;
}
@Override
- public Class<? extends RLFormatSQLVisitor> getRLVisitorClass() {
+ public Class<? extends RLSQLVisitor> getRLVisitorClass() {
return MySQLRLFormatSQLVisitor.class;
}
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLDALFormatSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLDALFormatSQLVisitor.java
index 337d5d6..bb33990 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLDALFormatSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLDALFormatSQLVisitor.java
@@ -17,10 +17,11 @@
package org.apache.shardingsphere.sql.parser.mysql.visitor.format.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DALFormatSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.format.SQLFormatVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DALSQLVisitor;
/**
* DAL Format SQL visitor for MySQL.
*/
-public final class MySQLDALFormatSQLVisitor extends MySQLFormatSQLVisitor implements DALFormatSQLVisitor {
+public final class MySQLDALFormatSQLVisitor extends MySQLFormatSQLVisitor implements DALSQLVisitor, SQLFormatVisitor {
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLDCLFormatSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLDCLFormatSQLVisitor.java
index 87b3397..c1f1de3 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLDCLFormatSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLDCLFormatSQLVisitor.java
@@ -17,10 +17,11 @@
package org.apache.shardingsphere.sql.parser.mysql.visitor.format.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DCLFormatSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.format.SQLFormatVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DCLSQLVisitor;
/**
* DCL Format SQL visitor for MySQL.
*/
-public final class MySQLDCLFormatSQLVisitor extends MySQLFormatSQLVisitor implements DCLFormatSQLVisitor {
+public final class MySQLDCLFormatSQLVisitor extends MySQLFormatSQLVisitor implements DCLSQLVisitor, SQLFormatVisitor {
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLDDLFormatSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLDDLFormatSQLVisitor.java
index 9e0db9a..3712631 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLDDLFormatSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLDDLFormatSQLVisitor.java
@@ -17,10 +17,11 @@
package org.apache.shardingsphere.sql.parser.mysql.visitor.format.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DDLFormatSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.format.SQLFormatVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DDLSQLVisitor;
/**
* DDL Format SQL visitor for MySQL.
*/
-public final class MySQLDDLFormatSQLVisitor extends MySQLFormatSQLVisitor implements DDLFormatSQLVisitor {
+public final class MySQLDDLFormatSQLVisitor extends MySQLFormatSQLVisitor implements DDLSQLVisitor, SQLFormatVisitor {
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLDMLFormatSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLDMLFormatSQLVisitor.java
index fabdca7..23e1210 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLDMLFormatSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLDMLFormatSQLVisitor.java
@@ -17,10 +17,11 @@
package org.apache.shardingsphere.sql.parser.mysql.visitor.format.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DMLFormatSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.format.SQLFormatVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DMLSQLVisitor;
/**
* DML Format SQL visitor for MySQL.
*/
-public final class MySQLDMLFormatSQLVisitor extends MySQLFormatSQLVisitor implements DMLFormatSQLVisitor {
+public final class MySQLDMLFormatSQLVisitor extends MySQLFormatSQLVisitor implements DMLSQLVisitor, SQLFormatVisitor {
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLRLFormatSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLRLFormatSQLVisitor.java
index b1965d7..d3bd7cb 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLRLFormatSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLRLFormatSQLVisitor.java
@@ -17,10 +17,11 @@
package org.apache.shardingsphere.sql.parser.mysql.visitor.format.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.RLFormatSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.format.SQLFormatVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.RLSQLVisitor;
/**
* RL Format SQL visitor for MySQL.
*/
-public final class MySQLRLFormatSQLVisitor extends MySQLFormatSQLVisitor implements RLFormatSQLVisitor {
+public final class MySQLRLFormatSQLVisitor extends MySQLFormatSQLVisitor implements RLSQLVisitor, SQLFormatVisitor {
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLTCLFormatSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLTCLFormatSQLVisitor.java
index 84f8720..9579be0 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLTCLFormatSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/format/impl/MySQLTCLFormatSQLVisitor.java
@@ -17,10 +17,11 @@
package org.apache.shardingsphere.sql.parser.mysql.visitor.format.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.TCLFormatSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.format.SQLFormatVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.TCLSQLVisitor;
/**
* TCL Format SQL visitor for MySQL.
*/
-public final class MySQLTCLFormatSQLVisitor extends MySQLFormatSQLVisitor implements TCLFormatSQLVisitor {
+public final class MySQLTCLFormatSQLVisitor extends MySQLFormatSQLVisitor implements TCLSQLVisitor, SQLFormatVisitor {
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/facade/MySQLStatementSQLVisitorFacade.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/facade/MySQLStatementSQLVisitorFacade.java
index 9babe84..86a917d 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/facade/MySQLStatementSQLVisitorFacade.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/facade/MySQLStatementSQLVisitorFacade.java
@@ -17,13 +17,13 @@
package org.apache.shardingsphere.sql.parser.mysql.visitor.statement.facade;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.facade.StatementSQLVisitorFacade;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DALStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DCLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DDLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DMLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.RLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.TCLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DALSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DCLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DDLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DMLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.RLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.TCLSQLVisitor;
import org.apache.shardingsphere.sql.parser.mysql.visitor.statement.impl.MySQLDALStatementSQLVisitor;
import org.apache.shardingsphere.sql.parser.mysql.visitor.statement.impl.MySQLDCLStatementSQLVisitor;
import org.apache.shardingsphere.sql.parser.mysql.visitor.statement.impl.MySQLDDLStatementSQLVisitor;
@@ -34,35 +34,35 @@ import org.apache.shardingsphere.sql.parser.mysql.visitor.statement.impl.MySQLTC
/**
* Statement SQL Visitor facade for MySQL.
*/
-public final class MySQLStatementSQLVisitorFacade implements StatementSQLVisitorFacade {
+public final class MySQLStatementSQLVisitorFacade implements SQLStatementVisitorFacade {
@Override
- public Class<? extends DMLStatementSQLVisitor> getDMLVisitorClass() {
+ public Class<? extends DMLSQLVisitor> getDMLVisitorClass() {
return MySQLDMLStatementSQLVisitor.class;
}
@Override
- public Class<? extends DDLStatementSQLVisitor> getDDLVisitorClass() {
+ public Class<? extends DDLSQLVisitor> getDDLVisitorClass() {
return MySQLDDLStatementSQLVisitor.class;
}
@Override
- public Class<? extends TCLStatementSQLVisitor> getTCLVisitorClass() {
+ public Class<? extends TCLSQLVisitor> getTCLVisitorClass() {
return MySQLTCLStatementSQLVisitor.class;
}
@Override
- public Class<? extends DCLStatementSQLVisitor> getDCLVisitorClass() {
+ public Class<? extends DCLSQLVisitor> getDCLVisitorClass() {
return MySQLDCLStatementSQLVisitor.class;
}
@Override
- public Class<? extends DALStatementSQLVisitor> getDALVisitorClass() {
+ public Class<? extends DALSQLVisitor> getDALVisitorClass() {
return MySQLDALStatementSQLVisitor.class;
}
@Override
- public Class<? extends RLStatementSQLVisitor> getRLVisitorClass() {
+ public Class<? extends RLSQLVisitor> getRLVisitorClass() {
return MySQLRLStatementSQLVisitor.class;
}
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLDALStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLDALStatementSQLVisitor.java
index efff14f..4e9f86b 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLDALStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLDALStatementSQLVisitor.java
@@ -17,11 +17,9 @@
package org.apache.shardingsphere.sql.parser.mysql.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DALStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.SetCharacterContext;
-import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.SetNameContext;
-import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.VariableAssignContext;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DALSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.AnalyzeTableContext;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.CacheIndexContext;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.ChecksumTableContext;
@@ -36,6 +34,8 @@ import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.Optimiz
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.RepairTableContext;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.ResetStatementContext;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.SchemaNameContext;
+import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.SetCharacterContext;
+import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.SetNameContext;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.SetVariableContext;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.ShowBinaryLogsContext;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.ShowBinlogEventsContext;
@@ -56,6 +56,7 @@ import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.ShowTab
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.ShowWarningsContext;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.UninstallPluginContext;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.UseContext;
+import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.VariableAssignContext;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.VariableContext;
import org.apache.shardingsphere.sql.parser.sql.common.segment.dal.FromSchemaSegment;
import org.apache.shardingsphere.sql.parser.sql.common.segment.dal.FromTableSegment;
@@ -64,7 +65,8 @@ import org.apache.shardingsphere.sql.parser.sql.common.segment.dal.VariableAssig
import org.apache.shardingsphere.sql.parser.sql.common.segment.dal.VariableSegment;
import org.apache.shardingsphere.sql.parser.sql.common.segment.generic.SchemaSegment;
import org.apache.shardingsphere.sql.parser.sql.common.segment.generic.table.SimpleTableSegment;
-import org.apache.shardingsphere.sql.parser.sql.dialect.statement.mysql.dal.MySQLSetStatement;
+import org.apache.shardingsphere.sql.parser.sql.common.value.identifier.IdentifierValue;
+import org.apache.shardingsphere.sql.parser.sql.common.value.literal.impl.StringLiteralValue;
import org.apache.shardingsphere.sql.parser.sql.dialect.statement.mysql.dal.MySQLAnalyzeTableStatement;
import org.apache.shardingsphere.sql.parser.sql.dialect.statement.mysql.dal.MySQLCacheIndexStatement;
import org.apache.shardingsphere.sql.parser.sql.dialect.statement.mysql.dal.MySQLChecksumTableStatement;
@@ -76,6 +78,7 @@ import org.apache.shardingsphere.sql.parser.sql.dialect.statement.mysql.dal.MySQ
import org.apache.shardingsphere.sql.parser.sql.dialect.statement.mysql.dal.MySQLOptimizeTableStatement;
import org.apache.shardingsphere.sql.parser.sql.dialect.statement.mysql.dal.MySQLRepairTableStatement;
import org.apache.shardingsphere.sql.parser.sql.dialect.statement.mysql.dal.MySQLResetStatement;
+import org.apache.shardingsphere.sql.parser.sql.dialect.statement.mysql.dal.MySQLSetStatement;
import org.apache.shardingsphere.sql.parser.sql.dialect.statement.mysql.dal.MySQLShowBinaryLogsStatement;
import org.apache.shardingsphere.sql.parser.sql.dialect.statement.mysql.dal.MySQLShowBinlogStatement;
import org.apache.shardingsphere.sql.parser.sql.dialect.statement.mysql.dal.MySQLShowColumnsStatement;
@@ -94,8 +97,6 @@ import org.apache.shardingsphere.sql.parser.sql.dialect.statement.mysql.dal.MySQ
import org.apache.shardingsphere.sql.parser.sql.dialect.statement.mysql.dal.MySQLShowWarningsStatement;
import org.apache.shardingsphere.sql.parser.sql.dialect.statement.mysql.dal.MySQLUninstallPluginStatement;
import org.apache.shardingsphere.sql.parser.sql.dialect.statement.mysql.dal.MySQLUseStatement;
-import org.apache.shardingsphere.sql.parser.sql.common.value.identifier.IdentifierValue;
-import org.apache.shardingsphere.sql.parser.sql.common.value.literal.impl.StringLiteralValue;
import java.util.Collection;
import java.util.LinkedList;
@@ -103,7 +104,7 @@ import java.util.LinkedList;
/**
* DAL Statement SQL visitor for MySQL.
*/
-public final class MySQLDALStatementSQLVisitor extends MySQLStatementSQLVisitor implements DALStatementSQLVisitor {
+public final class MySQLDALStatementSQLVisitor extends MySQLStatementSQLVisitor implements DALSQLVisitor, SQLStatementVisitor {
@Override
public ASTNode visitUninstallPlugin(final UninstallPluginContext ctx) {
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLDCLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLDCLStatementSQLVisitor.java
index d632f0c..07c4920 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLDCLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLDCLStatementSQLVisitor.java
@@ -17,8 +17,9 @@
package org.apache.shardingsphere.sql.parser.mysql.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DCLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DCLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.AlterUserContext;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.CreateRoleContext;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.CreateUserContext;
@@ -50,7 +51,7 @@ import java.util.Optional;
/**
* DCL Statement SQL visitor for MySQL.
*/
-public final class MySQLDCLStatementSQLVisitor extends MySQLStatementSQLVisitor implements DCLStatementSQLVisitor {
+public final class MySQLDCLStatementSQLVisitor extends MySQLStatementSQLVisitor implements DCLSQLVisitor, SQLStatementVisitor {
@Override
public ASTNode visitGrant(final GrantContext ctx) {
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLDDLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLDDLStatementSQLVisitor.java
index 7407565..5fe77c0 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLDDLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLDDLStatementSQLVisitor.java
@@ -19,8 +19,9 @@ package org.apache.shardingsphere.sql.parser.mysql.visitor.statement.impl;
import com.google.common.base.Preconditions;
import org.antlr.v4.runtime.Token;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DDLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DDLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.AddColumnSpecificationContext;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.AlterDatabaseContext;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.AlterDefinitionClauseContext;
@@ -150,7 +151,7 @@ import java.util.List;
/**
* DDL Statement SQL visitor for MySQL.
*/
-public final class MySQLDDLStatementSQLVisitor extends MySQLStatementSQLVisitor implements DDLStatementSQLVisitor {
+public final class MySQLDDLStatementSQLVisitor extends MySQLStatementSQLVisitor implements DDLSQLVisitor, SQLStatementVisitor {
@Override
public ASTNode visitCreateView(final CreateViewContext ctx) {
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLDMLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLDMLStatementSQLVisitor.java
index bad364b..19c0d4d 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLDMLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLDMLStatementSQLVisitor.java
@@ -17,8 +17,9 @@
package org.apache.shardingsphere.sql.parser.mysql.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DMLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DMLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.CallContext;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.DoStatementContext;
import org.apache.shardingsphere.sql.parser.sql.dialect.statement.mysql.dml.MySQLCallStatement;
@@ -27,7 +28,7 @@ import org.apache.shardingsphere.sql.parser.sql.dialect.statement.mysql.dml.MySQ
/**
* DML Statement SQL visitor for MySQL.
*/
-public final class MySQLDMLStatementSQLVisitor extends MySQLStatementSQLVisitor implements DMLStatementSQLVisitor {
+public final class MySQLDMLStatementSQLVisitor extends MySQLStatementSQLVisitor implements DMLSQLVisitor, SQLStatementVisitor {
@Override
public ASTNode visitCall(final CallContext ctx) {
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLRLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLRLStatementSQLVisitor.java
index 53f8fab..1032750 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLRLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLRLStatementSQLVisitor.java
@@ -17,8 +17,9 @@
package org.apache.shardingsphere.sql.parser.mysql.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.RLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.RLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.ChangeMasterToContext;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.StartSlaveContext;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.StopSlaveContext;
@@ -29,7 +30,7 @@ import org.apache.shardingsphere.sql.parser.sql.dialect.statement.mysql.rl.MySQL
/**
* RL Statement SQL visitor for MySQL.
*/
-public final class MySQLRLStatementSQLVisitor extends MySQLStatementSQLVisitor implements RLStatementSQLVisitor {
+public final class MySQLRLStatementSQLVisitor extends MySQLStatementSQLVisitor implements RLSQLVisitor, SQLStatementVisitor {
@Override public ASTNode visitChangeMasterTo(final ChangeMasterToContext ctx) {
return new MySQLChangeMasterStatement();
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLStatementSQLVisitor.java
index 586e930..46c810d 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLStatementSQLVisitor.java
@@ -21,7 +21,7 @@ import lombok.AccessLevel;
import lombok.Getter;
import org.antlr.v4.runtime.misc.Interval;
import org.antlr.v4.runtime.tree.TerminalNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementBaseVisitor;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.AggregationFunctionContext;
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLTCLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLTCLStatementSQLVisitor.java
index 9b6c4e8..b983479 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLTCLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLTCLStatementSQLVisitor.java
@@ -17,8 +17,9 @@
package org.apache.shardingsphere.sql.parser.mysql.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.TCLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.TCLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.AutoCommitValueContext;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.BeginTransactionContext;
import org.apache.shardingsphere.sql.parser.autogen.MySQLStatementParser.CommitContext;
@@ -39,7 +40,7 @@ import org.apache.shardingsphere.sql.parser.sql.dialect.statement.mysql.tcl.MySQ
/**
* TCL Statement SQL visitor for MySQL.
*/
-public final class MySQLTCLStatementSQLVisitor extends MySQLStatementSQLVisitor implements TCLStatementSQLVisitor {
+public final class MySQLTCLStatementSQLVisitor extends MySQLStatementSQLVisitor implements TCLSQLVisitor, SQLStatementVisitor {
@Override
public ASTNode visitSetTransaction(final SetTransactionContext ctx) {
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/parser/OracleParser.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/parser/OracleParser.java
index 1463644..990f88c 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/parser/OracleParser.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/parser/OracleParser.java
@@ -18,7 +18,7 @@
package org.apache.shardingsphere.sql.parser.oracle.parser;
import org.antlr.v4.runtime.TokenStream;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
import org.apache.shardingsphere.sql.parser.api.parser.SQLParser;
import org.apache.shardingsphere.sql.parser.autogen.OracleStatementParser;
import org.apache.shardingsphere.sql.parser.core.ParseASTNode;
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/OracleSQLVisitorFacadeFactory.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/OracleSQLVisitorFacadeFactory.java
index bd82475..b464df3 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/OracleSQLVisitorFacadeFactory.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/OracleSQLVisitorFacadeFactory.java
@@ -18,8 +18,8 @@
package org.apache.shardingsphere.sql.parser.oracle.visitor;
import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitorFacadeFactory;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.facade.FormatSQLVisitorFacade;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.facade.StatementSQLVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.format.SQLFormatVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitorFacade;
import org.apache.shardingsphere.sql.parser.oracle.visitor.format.facade.OracleFormatSQLVisitorFacade;
import org.apache.shardingsphere.sql.parser.oracle.visitor.statement.facade.OracleStatementSQLVisitorFacade;
@@ -29,12 +29,12 @@ import org.apache.shardingsphere.sql.parser.oracle.visitor.statement.facade.Orac
public final class OracleSQLVisitorFacadeFactory implements SQLVisitorFacadeFactory {
@Override
- public Class<? extends StatementSQLVisitorFacade> getStatementSQLVisitorFacadeClass() {
+ public Class<? extends SQLStatementVisitorFacade> getStatementSQLVisitorFacadeClass() {
return OracleStatementSQLVisitorFacade.class;
}
@Override
- public Class<? extends FormatSQLVisitorFacade> getFormatSQLVisitorFacadeClass() {
+ public Class<? extends SQLFormatVisitorFacade> getFormatSQLVisitorFacadeClass() {
return OracleFormatSQLVisitorFacade.class;
}
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/format/facade/OracleFormatSQLVisitorFacade.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/format/facade/OracleFormatSQLVisitorFacade.java
index 2cc8992..7c1fd4c 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/format/facade/OracleFormatSQLVisitorFacade.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/format/facade/OracleFormatSQLVisitorFacade.java
@@ -17,46 +17,46 @@
package org.apache.shardingsphere.sql.parser.oracle.visitor.format.facade;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.facade.FormatSQLVisitorFacade;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DALFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DCLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DDLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DMLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.RLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.TCLFormatSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.format.SQLFormatVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DALSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DCLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DDLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DMLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.RLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.TCLSQLVisitor;
/**
* Format SQL Visitor facade for MySQL.
*/
-public final class OracleFormatSQLVisitorFacade implements FormatSQLVisitorFacade {
+public final class OracleFormatSQLVisitorFacade implements SQLFormatVisitorFacade {
@Override
- public Class<? extends DMLFormatSQLVisitor> getDMLVisitorClass() {
+ public Class<? extends DMLSQLVisitor> getDMLVisitorClass() {
throw new UnsupportedOperationException();
}
@Override
- public Class<? extends DDLFormatSQLVisitor> getDDLVisitorClass() {
+ public Class<? extends DDLSQLVisitor> getDDLVisitorClass() {
throw new UnsupportedOperationException();
}
@Override
- public Class<? extends TCLFormatSQLVisitor> getTCLVisitorClass() {
+ public Class<? extends TCLSQLVisitor> getTCLVisitorClass() {
throw new UnsupportedOperationException();
}
@Override
- public Class<? extends DCLFormatSQLVisitor> getDCLVisitorClass() {
+ public Class<? extends DCLSQLVisitor> getDCLVisitorClass() {
throw new UnsupportedOperationException();
}
@Override
- public Class<? extends DALFormatSQLVisitor> getDALVisitorClass() {
+ public Class<? extends DALSQLVisitor> getDALVisitorClass() {
throw new UnsupportedOperationException();
}
@Override
- public Class<? extends RLFormatSQLVisitor> getRLVisitorClass() {
+ public Class<? extends RLSQLVisitor> getRLVisitorClass() {
throw new UnsupportedOperationException();
}
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/facade/OracleStatementSQLVisitorFacade.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/facade/OracleStatementSQLVisitorFacade.java
index f9fb666..e5441b2 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/facade/OracleStatementSQLVisitorFacade.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/facade/OracleStatementSQLVisitorFacade.java
@@ -17,13 +17,13 @@
package org.apache.shardingsphere.sql.parser.oracle.visitor.statement.facade;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.facade.StatementSQLVisitorFacade;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DALStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DCLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DDLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DMLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.RLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.TCLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DALSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DCLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DDLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DMLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.RLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.TCLSQLVisitor;
import org.apache.shardingsphere.sql.parser.oracle.visitor.statement.impl.OracleDALStatementSQLVisitor;
import org.apache.shardingsphere.sql.parser.oracle.visitor.statement.impl.OracleDCLStatementSQLVisitor;
import org.apache.shardingsphere.sql.parser.oracle.visitor.statement.impl.OracleDDLStatementSQLVisitor;
@@ -33,35 +33,35 @@ import org.apache.shardingsphere.sql.parser.oracle.visitor.statement.impl.Oracle
/**
* Visitor facade for Oracle.
*/
-public final class OracleStatementSQLVisitorFacade implements StatementSQLVisitorFacade {
+public final class OracleStatementSQLVisitorFacade implements SQLStatementVisitorFacade {
@Override
- public Class<? extends DMLStatementSQLVisitor> getDMLVisitorClass() {
+ public Class<? extends DMLSQLVisitor> getDMLVisitorClass() {
return OracleDMLStatementSQLVisitor.class;
}
@Override
- public Class<? extends DDLStatementSQLVisitor> getDDLVisitorClass() {
+ public Class<? extends DDLSQLVisitor> getDDLVisitorClass() {
return OracleDDLStatementSQLVisitor.class;
}
@Override
- public Class<? extends TCLStatementSQLVisitor> getTCLVisitorClass() {
+ public Class<? extends TCLSQLVisitor> getTCLVisitorClass() {
return OracleTCLStatementSQLVisitor.class;
}
@Override
- public Class<? extends DCLStatementSQLVisitor> getDCLVisitorClass() {
+ public Class<? extends DCLSQLVisitor> getDCLVisitorClass() {
return OracleDCLStatementSQLVisitor.class;
}
@Override
- public Class<? extends DALStatementSQLVisitor> getDALVisitorClass() {
+ public Class<? extends DALSQLVisitor> getDALVisitorClass() {
return OracleDALStatementSQLVisitor.class;
}
@Override
- public Class<? extends RLStatementSQLVisitor> getRLVisitorClass() {
+ public Class<? extends RLSQLVisitor> getRLVisitorClass() {
return null;
}
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleDALStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleDALStatementSQLVisitor.java
index b2fb1f2..4746a70 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleDALStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleDALStatementSQLVisitor.java
@@ -17,10 +17,11 @@
package org.apache.shardingsphere.sql.parser.oracle.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DALStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DALSQLVisitor;
/**
* DAL Statement SQL visitor for Oracle.
*/
-public final class OracleDALStatementSQLVisitor extends OracleStatementSQLVisitor implements DALStatementSQLVisitor {
+public final class OracleDALStatementSQLVisitor extends OracleStatementSQLVisitor implements DALSQLVisitor, SQLStatementVisitor {
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleDCLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleDCLStatementSQLVisitor.java
index ec51b28..e8c209b 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleDCLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleDCLStatementSQLVisitor.java
@@ -17,8 +17,9 @@
package org.apache.shardingsphere.sql.parser.oracle.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DCLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DCLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.OracleStatementParser.AlterRoleContext;
import org.apache.shardingsphere.sql.parser.autogen.OracleStatementParser.AlterUserContext;
import org.apache.shardingsphere.sql.parser.autogen.OracleStatementParser.CreateRoleContext;
@@ -44,7 +45,7 @@ import java.util.Collections;
/**
* DCL Statement SQL visitor for Oracle.
*/
-public final class OracleDCLStatementSQLVisitor extends OracleStatementSQLVisitor implements DCLStatementSQLVisitor {
+public final class OracleDCLStatementSQLVisitor extends OracleStatementSQLVisitor implements DCLSQLVisitor, SQLStatementVisitor {
@Override
public ASTNode visitGrant(final GrantContext ctx) {
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleDDLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleDDLStatementSQLVisitor.java
index 862cfc5..3a2d217 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleDDLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleDDLStatementSQLVisitor.java
@@ -17,8 +17,9 @@
package org.apache.shardingsphere.sql.parser.oracle.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DDLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DDLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.OracleStatementParser.AddColumnSpecificationContext;
import org.apache.shardingsphere.sql.parser.autogen.OracleStatementParser.AlterDefinitionClauseContext;
import org.apache.shardingsphere.sql.parser.autogen.OracleStatementParser.AlterIndexContext;
@@ -66,7 +67,7 @@ import java.util.LinkedList;
/**
* DDL Statement SQL visitor for Oracle.
*/
-public final class OracleDDLStatementSQLVisitor extends OracleStatementSQLVisitor implements DDLStatementSQLVisitor {
+public final class OracleDDLStatementSQLVisitor extends OracleStatementSQLVisitor implements DDLSQLVisitor, SQLStatementVisitor {
@SuppressWarnings("unchecked")
@Override
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleDMLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleDMLStatementSQLVisitor.java
index f02ace0..9e641a6 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleDMLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleDMLStatementSQLVisitor.java
@@ -17,8 +17,9 @@
package org.apache.shardingsphere.sql.parser.oracle.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DMLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DMLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.OracleStatementParser.AliasContext;
import org.apache.shardingsphere.sql.parser.autogen.OracleStatementParser.AssignmentContext;
import org.apache.shardingsphere.sql.parser.autogen.OracleStatementParser.AssignmentValueContext;
@@ -98,7 +99,7 @@ import java.util.List;
/**
* DML Statement SQL visitor for Oracle.
*/
-public final class OracleDMLStatementSQLVisitor extends OracleStatementSQLVisitor implements DMLStatementSQLVisitor {
+public final class OracleDMLStatementSQLVisitor extends OracleStatementSQLVisitor implements DMLSQLVisitor, SQLStatementVisitor {
@Override
public ASTNode visitInsert(final InsertContext ctx) {
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleStatementSQLVisitor.java
index 0909cbe..1b35ef9 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleStatementSQLVisitor.java
@@ -23,7 +23,7 @@ import lombok.Getter;
import org.antlr.v4.runtime.ParserRuleContext;
import org.antlr.v4.runtime.misc.Interval;
import org.antlr.v4.runtime.tree.TerminalNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
import org.apache.shardingsphere.sql.parser.autogen.OracleStatementBaseVisitor;
import org.apache.shardingsphere.sql.parser.autogen.OracleStatementParser;
import org.apache.shardingsphere.sql.parser.autogen.OracleStatementParser.AggregationFunctionContext;
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleTCLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleTCLStatementSQLVisitor.java
index fdd1547..2ee9286 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleTCLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/java/org/apache/shardingsphere/sql/parser/oracle/visitor/statement/impl/OracleTCLStatementSQLVisitor.java
@@ -17,8 +17,9 @@
package org.apache.shardingsphere.sql.parser.oracle.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.TCLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.TCLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.OracleStatementParser.CommitContext;
import org.apache.shardingsphere.sql.parser.autogen.OracleStatementParser.RollbackContext;
import org.apache.shardingsphere.sql.parser.autogen.OracleStatementParser.SavepointContext;
@@ -31,7 +32,7 @@ import org.apache.shardingsphere.sql.parser.sql.dialect.statement.oracle.tcl.Ora
/**
* TCL Statement SQL visitor for Oracle.
*/
-public final class OracleTCLStatementSQLVisitor extends OracleStatementSQLVisitor implements TCLStatementSQLVisitor {
+public final class OracleTCLStatementSQLVisitor extends OracleStatementSQLVisitor implements TCLSQLVisitor, SQLStatementVisitor {
@Override
public ASTNode visitSetTransaction(final SetTransactionContext ctx) {
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/parser/PostgreSQLParser.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/parser/PostgreSQLParser.java
index c0583cb..10f9250 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/parser/PostgreSQLParser.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/parser/PostgreSQLParser.java
@@ -18,7 +18,7 @@
package org.apache.shardingsphere.sql.parser.postgresql.parser;
import org.antlr.v4.runtime.TokenStream;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
import org.apache.shardingsphere.sql.parser.api.parser.SQLParser;
import org.apache.shardingsphere.sql.parser.autogen.PostgreSQLStatementParser;
import org.apache.shardingsphere.sql.parser.core.ParseASTNode;
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/PostgreSQLSQLVisitorFacadeFactory.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/PostgreSQLSQLVisitorFacadeFactory.java
index c2cae8d..3709ee6 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/PostgreSQLSQLVisitorFacadeFactory.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/PostgreSQLSQLVisitorFacadeFactory.java
@@ -18,8 +18,8 @@
package org.apache.shardingsphere.sql.parser.postgresql.visitor;
import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitorFacadeFactory;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.facade.FormatSQLVisitorFacade;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.facade.StatementSQLVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.format.SQLFormatVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitorFacade;
import org.apache.shardingsphere.sql.parser.postgresql.visitor.format.facade.PostgreSQLFormatSQLVisitorFacade;
import org.apache.shardingsphere.sql.parser.postgresql.visitor.statement.facade.PostgreSQLStatementSQLVisitorFacade;
@@ -29,12 +29,12 @@ import org.apache.shardingsphere.sql.parser.postgresql.visitor.statement.facade.
public final class PostgreSQLSQLVisitorFacadeFactory implements SQLVisitorFacadeFactory {
@Override
- public Class<? extends StatementSQLVisitorFacade> getStatementSQLVisitorFacadeClass() {
+ public Class<? extends SQLStatementVisitorFacade> getStatementSQLVisitorFacadeClass() {
return PostgreSQLStatementSQLVisitorFacade.class;
}
@Override
- public Class<? extends FormatSQLVisitorFacade> getFormatSQLVisitorFacadeClass() {
+ public Class<? extends SQLFormatVisitorFacade> getFormatSQLVisitorFacadeClass() {
return PostgreSQLFormatSQLVisitorFacade.class;
}
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/format/facade/PostgreSQLFormatSQLVisitorFacade.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/format/facade/PostgreSQLFormatSQLVisitorFacade.java
index eec8f2e..39afcd3 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/format/facade/PostgreSQLFormatSQLVisitorFacade.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/format/facade/PostgreSQLFormatSQLVisitorFacade.java
@@ -17,46 +17,46 @@
package org.apache.shardingsphere.sql.parser.postgresql.visitor.format.facade;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.facade.FormatSQLVisitorFacade;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DALFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DCLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DDLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DMLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.RLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.TCLFormatSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.format.SQLFormatVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DALSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DCLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DDLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DMLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.RLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.TCLSQLVisitor;
/**
* Format SQL Visitor facade for MySQL.
*/
-public final class PostgreSQLFormatSQLVisitorFacade implements FormatSQLVisitorFacade {
+public final class PostgreSQLFormatSQLVisitorFacade implements SQLFormatVisitorFacade {
@Override
- public Class<? extends DMLFormatSQLVisitor> getDMLVisitorClass() {
+ public Class<? extends DMLSQLVisitor> getDMLVisitorClass() {
throw new UnsupportedOperationException();
}
@Override
- public Class<? extends DDLFormatSQLVisitor> getDDLVisitorClass() {
+ public Class<? extends DDLSQLVisitor> getDDLVisitorClass() {
throw new UnsupportedOperationException();
}
@Override
- public Class<? extends TCLFormatSQLVisitor> getTCLVisitorClass() {
+ public Class<? extends TCLSQLVisitor> getTCLVisitorClass() {
throw new UnsupportedOperationException();
}
@Override
- public Class<? extends DCLFormatSQLVisitor> getDCLVisitorClass() {
+ public Class<? extends DCLSQLVisitor> getDCLVisitorClass() {
throw new UnsupportedOperationException();
}
@Override
- public Class<? extends DALFormatSQLVisitor> getDALVisitorClass() {
+ public Class<? extends DALSQLVisitor> getDALVisitorClass() {
throw new UnsupportedOperationException();
}
@Override
- public Class<? extends RLFormatSQLVisitor> getRLVisitorClass() {
+ public Class<? extends RLSQLVisitor> getRLVisitorClass() {
throw new UnsupportedOperationException();
}
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/facade/PostgreSQLStatementSQLVisitorFacade.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/facade/PostgreSQLStatementSQLVisitorFacade.java
index 5bb87b8..adcff7a 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/facade/PostgreSQLStatementSQLVisitorFacade.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/facade/PostgreSQLStatementSQLVisitorFacade.java
@@ -17,13 +17,13 @@
package org.apache.shardingsphere.sql.parser.postgresql.visitor.statement.facade;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.facade.StatementSQLVisitorFacade;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DALStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DCLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DDLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DMLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.RLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.TCLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DALSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DCLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DDLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DMLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.RLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.TCLSQLVisitor;
import org.apache.shardingsphere.sql.parser.postgresql.visitor.statement.impl.PostgreSQLDALStatementSQLVisitor;
import org.apache.shardingsphere.sql.parser.postgresql.visitor.statement.impl.PostgreSQLDCLStatementSQLVisitor;
import org.apache.shardingsphere.sql.parser.postgresql.visitor.statement.impl.PostgreSQLDDLStatementSQLVisitor;
@@ -33,35 +33,35 @@ import org.apache.shardingsphere.sql.parser.postgresql.visitor.statement.impl.Po
/**
* Statement SQL Visitor facade for PostgreSQL.
*/
-public final class PostgreSQLStatementSQLVisitorFacade implements StatementSQLVisitorFacade {
+public final class PostgreSQLStatementSQLVisitorFacade implements SQLStatementVisitorFacade {
@Override
- public Class<? extends DMLStatementSQLVisitor> getDMLVisitorClass() {
+ public Class<? extends DMLSQLVisitor> getDMLVisitorClass() {
return PostgreSQLDMLStatementSQLVisitor.class;
}
@Override
- public Class<? extends DDLStatementSQLVisitor> getDDLVisitorClass() {
+ public Class<? extends DDLSQLVisitor> getDDLVisitorClass() {
return PostgreSQLDDLStatementSQLVisitor.class;
}
@Override
- public Class<? extends TCLStatementSQLVisitor> getTCLVisitorClass() {
+ public Class<? extends TCLSQLVisitor> getTCLVisitorClass() {
return PostgreSQLTCLStatementSQLVisitor.class;
}
@Override
- public Class<? extends DCLStatementSQLVisitor> getDCLVisitorClass() {
+ public Class<? extends DCLSQLVisitor> getDCLVisitorClass() {
return PostgreSQLDCLStatementSQLVisitor.class;
}
@Override
- public Class<? extends DALStatementSQLVisitor> getDALVisitorClass() {
+ public Class<? extends DALSQLVisitor> getDALVisitorClass() {
return PostgreSQLDALStatementSQLVisitor.class;
}
@Override
- public Class<? extends RLStatementSQLVisitor> getRLVisitorClass() {
+ public Class<? extends RLSQLVisitor> getRLVisitorClass() {
return null;
}
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLDALStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLDALStatementSQLVisitor.java
index 1ad89c9..edcca90 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLDALStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLDALStatementSQLVisitor.java
@@ -17,8 +17,9 @@
package org.apache.shardingsphere.sql.parser.postgresql.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DALStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DALSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.PostgreSQLStatementParser.AnalyzeContext;
import org.apache.shardingsphere.sql.parser.autogen.PostgreSQLStatementParser.ConfigurationParameterClauseContext;
import org.apache.shardingsphere.sql.parser.autogen.PostgreSQLStatementParser.ResetParameterContext;
@@ -37,7 +38,7 @@ import java.util.LinkedList;
/**
* DAL Statement SQL visitor for PostgreSQL.
*/
-public final class PostgreSQLDALStatementSQLVisitor extends PostgreSQLStatementSQLVisitor implements DALStatementSQLVisitor {
+public final class PostgreSQLDALStatementSQLVisitor extends PostgreSQLStatementSQLVisitor implements DALSQLVisitor, SQLStatementVisitor {
@Override
public ASTNode visitShow(final ShowContext ctx) {
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLDCLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLDCLStatementSQLVisitor.java
index 0cf1be8..fa4cb6f 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLDCLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLDCLStatementSQLVisitor.java
@@ -17,8 +17,9 @@
package org.apache.shardingsphere.sql.parser.postgresql.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DCLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DCLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.PostgreSQLStatementParser.AlterRoleContext;
import org.apache.shardingsphere.sql.parser.autogen.PostgreSQLStatementParser.AlterUserContext;
import org.apache.shardingsphere.sql.parser.autogen.PostgreSQLStatementParser.CreateRoleContext;
@@ -45,7 +46,7 @@ import java.util.Optional;
/**
* DCL Statement SQL visitor for PostgreSQL.
*/
-public final class PostgreSQLDCLStatementSQLVisitor extends PostgreSQLStatementSQLVisitor implements DCLStatementSQLVisitor {
+public final class PostgreSQLDCLStatementSQLVisitor extends PostgreSQLStatementSQLVisitor implements DCLSQLVisitor, SQLStatementVisitor {
@Override
public ASTNode visitGrant(final GrantContext ctx) {
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLDDLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLDDLStatementSQLVisitor.java
index 9bc9aac..56f8e9b 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLDDLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLDDLStatementSQLVisitor.java
@@ -17,8 +17,9 @@
package org.apache.shardingsphere.sql.parser.postgresql.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DDLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DDLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.PostgreSQLStatementParser.AddColumnSpecificationContext;
import org.apache.shardingsphere.sql.parser.autogen.PostgreSQLStatementParser.AlterDefinitionClauseContext;
import org.apache.shardingsphere.sql.parser.autogen.PostgreSQLStatementParser.AlterFunctionContext;
@@ -92,7 +93,7 @@ import java.util.LinkedList;
/**
* DDL Statement SQL visitor for PostgreSQL.
*/
-public final class PostgreSQLDDLStatementSQLVisitor extends PostgreSQLStatementSQLVisitor implements DDLStatementSQLVisitor {
+public final class PostgreSQLDDLStatementSQLVisitor extends PostgreSQLStatementSQLVisitor implements DDLSQLVisitor, SQLStatementVisitor {
@SuppressWarnings("unchecked")
@Override
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLDMLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLDMLStatementSQLVisitor.java
index 7421b54..e00c4aa 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLDMLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLDMLStatementSQLVisitor.java
@@ -18,8 +18,9 @@
package org.apache.shardingsphere.sql.parser.postgresql.visitor.statement.impl;
import org.antlr.v4.runtime.tree.ParseTree;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DMLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DMLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.PostgreSQLStatementParser.AExprContext;
import org.apache.shardingsphere.sql.parser.autogen.PostgreSQLStatementParser.AliasClauseContext;
import org.apache.shardingsphere.sql.parser.autogen.PostgreSQLStatementParser.AttrNameContext;
@@ -117,7 +118,7 @@ import java.util.List;
/**
* DML Statement SQL visitor for PostgreSQL.
*/
-public final class PostgreSQLDMLStatementSQLVisitor extends PostgreSQLStatementSQLVisitor implements DMLStatementSQLVisitor {
+public final class PostgreSQLDMLStatementSQLVisitor extends PostgreSQLStatementSQLVisitor implements DMLSQLVisitor, SQLStatementVisitor {
@Override
public ASTNode visitInsert(final InsertContext ctx) {
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLStatementSQLVisitor.java
index 911a18c..c422c5c 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLStatementSQLVisitor.java
@@ -22,7 +22,7 @@ import lombok.AccessLevel;
import lombok.Getter;
import org.antlr.v4.runtime.misc.Interval;
import org.antlr.v4.runtime.tree.TerminalNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
import org.apache.shardingsphere.sql.parser.autogen.PostgreSQLStatementBaseVisitor;
import org.apache.shardingsphere.sql.parser.autogen.PostgreSQLStatementParser.AExprContext;
import org.apache.shardingsphere.sql.parser.autogen.PostgreSQLStatementParser.AexprConstContext;
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLTCLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLTCLStatementSQLVisitor.java
index d17cd70..a19ae58 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLTCLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-postgresql/src/main/java/org/apache/shardingsphere/sql/parser/postgresql/visitor/statement/impl/PostgreSQLTCLStatementSQLVisitor.java
@@ -17,8 +17,9 @@
package org.apache.shardingsphere.sql.parser.postgresql.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.TCLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.TCLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.PostgreSQLStatementParser.BeginTransactionContext;
import org.apache.shardingsphere.sql.parser.autogen.PostgreSQLStatementParser.CommitContext;
import org.apache.shardingsphere.sql.parser.autogen.PostgreSQLStatementParser.RollbackContext;
@@ -33,7 +34,7 @@ import org.apache.shardingsphere.sql.parser.sql.dialect.statement.postgresql.tcl
/**
* TCL Statement SQL visitor for PostgreSQL.
*/
-public final class PostgreSQLTCLStatementSQLVisitor extends PostgreSQLStatementSQLVisitor implements TCLStatementSQLVisitor {
+public final class PostgreSQLTCLStatementSQLVisitor extends PostgreSQLStatementSQLVisitor implements TCLSQLVisitor, SQLStatementVisitor {
@Override
public ASTNode visitSetTransaction(final SetTransactionContext ctx) {
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/parser/SQL92Parser.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/parser/SQL92Parser.java
index d51dc05..dfa421d 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/parser/SQL92Parser.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/parser/SQL92Parser.java
@@ -18,7 +18,7 @@
package org.apache.shardingsphere.sql.parser.sql92.parser;
import org.antlr.v4.runtime.TokenStream;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
import org.apache.shardingsphere.sql.parser.api.parser.SQLParser;
import org.apache.shardingsphere.sql.parser.autogen.SQL92StatementParser;
import org.apache.shardingsphere.sql.parser.core.ParseASTNode;
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/SQL92SQLVisitorFacadeFactory.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/SQL92SQLVisitorFacadeFactory.java
index 7c3f652..b49664c 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/SQL92SQLVisitorFacadeFactory.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/SQL92SQLVisitorFacadeFactory.java
@@ -18,8 +18,8 @@
package org.apache.shardingsphere.sql.parser.sql92.visitor;
import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitorFacadeFactory;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.facade.FormatSQLVisitorFacade;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.facade.StatementSQLVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.format.SQLFormatVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitorFacade;
import org.apache.shardingsphere.sql.parser.sql92.visitor.format.facade.SQL92FormatSQLVisitorFacade;
import org.apache.shardingsphere.sql.parser.sql92.visitor.statement.facade.SQL92StatementSQLVisitorFacade;
@@ -29,12 +29,12 @@ import org.apache.shardingsphere.sql.parser.sql92.visitor.statement.facade.SQL92
public final class SQL92SQLVisitorFacadeFactory implements SQLVisitorFacadeFactory {
@Override
- public Class<? extends StatementSQLVisitorFacade> getStatementSQLVisitorFacadeClass() {
+ public Class<? extends SQLStatementVisitorFacade> getStatementSQLVisitorFacadeClass() {
return SQL92StatementSQLVisitorFacade.class;
}
@Override
- public Class<? extends FormatSQLVisitorFacade> getFormatSQLVisitorFacadeClass() {
+ public Class<? extends SQLFormatVisitorFacade> getFormatSQLVisitorFacadeClass() {
return SQL92FormatSQLVisitorFacade.class;
}
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/format/facade/SQL92FormatSQLVisitorFacade.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/format/facade/SQL92FormatSQLVisitorFacade.java
index f2d5a89..6fd6f34 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/format/facade/SQL92FormatSQLVisitorFacade.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/format/facade/SQL92FormatSQLVisitorFacade.java
@@ -17,46 +17,46 @@
package org.apache.shardingsphere.sql.parser.sql92.visitor.format.facade;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.facade.FormatSQLVisitorFacade;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DALFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DCLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DDLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DMLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.RLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.TCLFormatSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.format.SQLFormatVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DALSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DCLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DDLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DMLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.RLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.TCLSQLVisitor;
/**
* Format SQL Visitor facade for MySQL.
*/
-public final class SQL92FormatSQLVisitorFacade implements FormatSQLVisitorFacade {
+public final class SQL92FormatSQLVisitorFacade implements SQLFormatVisitorFacade {
@Override
- public Class<? extends DMLFormatSQLVisitor> getDMLVisitorClass() {
+ public Class<? extends DMLSQLVisitor> getDMLVisitorClass() {
throw new UnsupportedOperationException();
}
@Override
- public Class<? extends DDLFormatSQLVisitor> getDDLVisitorClass() {
+ public Class<? extends DDLSQLVisitor> getDDLVisitorClass() {
throw new UnsupportedOperationException();
}
@Override
- public Class<? extends TCLFormatSQLVisitor> getTCLVisitorClass() {
+ public Class<? extends TCLSQLVisitor> getTCLVisitorClass() {
throw new UnsupportedOperationException();
}
@Override
- public Class<? extends DCLFormatSQLVisitor> getDCLVisitorClass() {
+ public Class<? extends DCLSQLVisitor> getDCLVisitorClass() {
throw new UnsupportedOperationException();
}
@Override
- public Class<? extends DALFormatSQLVisitor> getDALVisitorClass() {
+ public Class<? extends DALSQLVisitor> getDALVisitorClass() {
throw new UnsupportedOperationException();
}
@Override
- public Class<? extends RLFormatSQLVisitor> getRLVisitorClass() {
+ public Class<? extends RLSQLVisitor> getRLVisitorClass() {
throw new UnsupportedOperationException();
}
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/facade/SQL92StatementSQLVisitorFacade.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/facade/SQL92StatementSQLVisitorFacade.java
index 2b65c09..ff225cb 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/facade/SQL92StatementSQLVisitorFacade.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/facade/SQL92StatementSQLVisitorFacade.java
@@ -17,13 +17,13 @@
package org.apache.shardingsphere.sql.parser.sql92.visitor.statement.facade;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.facade.StatementSQLVisitorFacade;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DALStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DCLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DDLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DMLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.RLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.TCLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DALSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DCLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DDLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DMLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.RLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.TCLSQLVisitor;
import org.apache.shardingsphere.sql.parser.sql92.visitor.statement.impl.SQL92DALStatementSQLVisitor;
import org.apache.shardingsphere.sql.parser.sql92.visitor.statement.impl.SQL92DCLStatementSQLVisitor;
import org.apache.shardingsphere.sql.parser.sql92.visitor.statement.impl.SQL92DDLStatementSQLVisitor;
@@ -33,35 +33,35 @@ import org.apache.shardingsphere.sql.parser.sql92.visitor.statement.impl.SQL92TC
/**
* Statement SQL Visitor facade for SQL92.
*/
-public final class SQL92StatementSQLVisitorFacade implements StatementSQLVisitorFacade {
+public final class SQL92StatementSQLVisitorFacade implements SQLStatementVisitorFacade {
@Override
- public Class<? extends DMLStatementSQLVisitor> getDMLVisitorClass() {
+ public Class<? extends DMLSQLVisitor> getDMLVisitorClass() {
return SQL92DMLStatementSQLVisitor.class;
}
@Override
- public Class<? extends DDLStatementSQLVisitor> getDDLVisitorClass() {
+ public Class<? extends DDLSQLVisitor> getDDLVisitorClass() {
return SQL92DDLStatementSQLVisitor.class;
}
@Override
- public Class<? extends TCLStatementSQLVisitor> getTCLVisitorClass() {
+ public Class<? extends TCLSQLVisitor> getTCLVisitorClass() {
return SQL92TCLStatementSQLVisitor.class;
}
@Override
- public Class<? extends DCLStatementSQLVisitor> getDCLVisitorClass() {
+ public Class<? extends DCLSQLVisitor> getDCLVisitorClass() {
return SQL92DCLStatementSQLVisitor.class;
}
@Override
- public Class<? extends DALStatementSQLVisitor> getDALVisitorClass() {
+ public Class<? extends DALSQLVisitor> getDALVisitorClass() {
return SQL92DALStatementSQLVisitor.class;
}
@Override
- public Class<? extends RLStatementSQLVisitor> getRLVisitorClass() {
+ public Class<? extends RLSQLVisitor> getRLVisitorClass() {
return null;
}
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92DALStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92DALStatementSQLVisitor.java
index e6c5091..3d50566 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92DALStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92DALStatementSQLVisitor.java
@@ -17,10 +17,11 @@
package org.apache.shardingsphere.sql.parser.sql92.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DALStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DALSQLVisitor;
/**
* DAL Statement SQL visitor for SQL92.
*/
-public final class SQL92DALStatementSQLVisitor extends SQL92StatementSQLVisitor implements DALStatementSQLVisitor {
+public final class SQL92DALStatementSQLVisitor extends SQL92StatementSQLVisitor implements DALSQLVisitor, SQLStatementVisitor {
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92DCLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92DCLStatementSQLVisitor.java
index 20d9578..97a898a 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92DCLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92DCLStatementSQLVisitor.java
@@ -17,8 +17,9 @@
package org.apache.shardingsphere.sql.parser.sql92.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DCLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DCLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.SQL92StatementParser.GrantContext;
import org.apache.shardingsphere.sql.parser.autogen.SQL92StatementParser.PrivilegeClauseContext;
import org.apache.shardingsphere.sql.parser.autogen.SQL92StatementParser.RevokeContext;
@@ -32,7 +33,7 @@ import java.util.Collections;
/**
* DCL Statement SQL visitor for SQL92.
*/
-public final class SQL92DCLStatementSQLVisitor extends SQL92StatementSQLVisitor implements DCLStatementSQLVisitor {
+public final class SQL92DCLStatementSQLVisitor extends SQL92StatementSQLVisitor implements DCLSQLVisitor, SQLStatementVisitor {
@Override
public ASTNode visitGrant(final GrantContext ctx) {
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92DDLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92DDLStatementSQLVisitor.java
index ae71a1a..5f29d6b 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92DDLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92DDLStatementSQLVisitor.java
@@ -17,8 +17,9 @@
package org.apache.shardingsphere.sql.parser.sql92.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DDLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DDLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.SQL92StatementParser.AddColumnSpecificationContext;
import org.apache.shardingsphere.sql.parser.autogen.SQL92StatementParser.AlterDefinitionClauseContext;
import org.apache.shardingsphere.sql.parser.autogen.SQL92StatementParser.AlterTableContext;
@@ -52,7 +53,7 @@ import java.util.Collections;
/**
* DDL Statement SQL visitor for SQL92.
*/
-public final class SQL92DDLStatementSQLVisitor extends SQL92StatementSQLVisitor implements DDLStatementSQLVisitor {
+public final class SQL92DDLStatementSQLVisitor extends SQL92StatementSQLVisitor implements DDLSQLVisitor, SQLStatementVisitor {
@SuppressWarnings("unchecked")
@Override
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92DMLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92DMLStatementSQLVisitor.java
index 469bd38..8ce61f4 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92DMLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92DMLStatementSQLVisitor.java
@@ -17,8 +17,9 @@
package org.apache.shardingsphere.sql.parser.sql92.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DMLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DMLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.SQL92StatementParser.AliasContext;
import org.apache.shardingsphere.sql.parser.autogen.SQL92StatementParser.AssignmentContext;
import org.apache.shardingsphere.sql.parser.autogen.SQL92StatementParser.AssignmentValueContext;
@@ -95,7 +96,7 @@ import java.util.List;
/**
* DML Statement SQL visitor for SQL92.
*/
-public final class SQL92DMLStatementSQLVisitor extends SQL92StatementSQLVisitor implements DMLStatementSQLVisitor {
+public final class SQL92DMLStatementSQLVisitor extends SQL92StatementSQLVisitor implements DMLSQLVisitor, SQLStatementVisitor {
@Override
public ASTNode visitInsert(final InsertContext ctx) {
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92StatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92StatementSQLVisitor.java
index 1064f38..9119962 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92StatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92StatementSQLVisitor.java
@@ -23,7 +23,7 @@ import lombok.Getter;
import org.antlr.v4.runtime.ParserRuleContext;
import org.antlr.v4.runtime.misc.Interval;
import org.antlr.v4.runtime.tree.TerminalNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
import org.apache.shardingsphere.sql.parser.autogen.SQL92StatementBaseVisitor;
import org.apache.shardingsphere.sql.parser.autogen.SQL92StatementParser.AggregationFunctionContext;
import org.apache.shardingsphere.sql.parser.autogen.SQL92StatementParser.BitExprContext;
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92TCLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92TCLStatementSQLVisitor.java
index 633ff32..aa079dd 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92TCLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sql92/src/main/java/org/apache/shardingsphere/sql/parser/sql92/visitor/statement/impl/SQL92TCLStatementSQLVisitor.java
@@ -17,8 +17,9 @@
package org.apache.shardingsphere.sql.parser.sql92.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.TCLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.TCLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.SQL92StatementParser.CommitContext;
import org.apache.shardingsphere.sql.parser.autogen.SQL92StatementParser.RollbackContext;
import org.apache.shardingsphere.sql.parser.autogen.SQL92StatementParser.SetTransactionContext;
@@ -29,7 +30,7 @@ import org.apache.shardingsphere.sql.parser.sql.dialect.statement.sql92.tcl.SQL9
/**
* TCL Statement SQL visitor for SQL92.
*/
-public final class SQL92TCLStatementSQLVisitor extends SQL92StatementSQLVisitor implements TCLStatementSQLVisitor {
+public final class SQL92TCLStatementSQLVisitor extends SQL92StatementSQLVisitor implements TCLSQLVisitor, SQLStatementVisitor {
@Override
public ASTNode visitSetTransaction(final SetTransactionContext ctx) {
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/parser/SQLServerParser.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/parser/SQLServerParser.java
index 8290479..1b7eef1 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/parser/SQLServerParser.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/parser/SQLServerParser.java
@@ -18,7 +18,7 @@
package org.apache.shardingsphere.sql.parser.sqlserver.parser;
import org.antlr.v4.runtime.TokenStream;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
import org.apache.shardingsphere.sql.parser.api.parser.SQLParser;
import org.apache.shardingsphere.sql.parser.autogen.SQLServerStatementParser;
import org.apache.shardingsphere.sql.parser.core.ParseASTNode;
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/SQLServerSQLVisitorFacadeFactory.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/SQLServerSQLVisitorFacadeFactory.java
index 0eb76b0..2f8732d 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/SQLServerSQLVisitorFacadeFactory.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/SQLServerSQLVisitorFacadeFactory.java
@@ -18,8 +18,8 @@
package org.apache.shardingsphere.sql.parser.sqlserver.visitor;
import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitorFacadeFactory;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.facade.FormatSQLVisitorFacade;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.facade.StatementSQLVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.format.SQLFormatVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitorFacade;
import org.apache.shardingsphere.sql.parser.sqlserver.visitor.statement.facade.SQLServerStatementSQLVisitorFacade;
import org.apache.shardingsphere.sql.parser.sqlserver.visitor.format.facade.SQLServerFormatSQLVisitorFacade;
@@ -29,12 +29,12 @@ import org.apache.shardingsphere.sql.parser.sqlserver.visitor.format.facade.SQLS
public final class SQLServerSQLVisitorFacadeFactory implements SQLVisitorFacadeFactory {
@Override
- public Class<? extends StatementSQLVisitorFacade> getStatementSQLVisitorFacadeClass() {
+ public Class<? extends SQLStatementVisitorFacade> getStatementSQLVisitorFacadeClass() {
return SQLServerStatementSQLVisitorFacade.class;
}
@Override
- public Class<? extends FormatSQLVisitorFacade> getFormatSQLVisitorFacadeClass() {
+ public Class<? extends SQLFormatVisitorFacade> getFormatSQLVisitorFacadeClass() {
return SQLServerFormatSQLVisitorFacade.class;
}
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/format/facade/SQLServerFormatSQLVisitorFacade.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/format/facade/SQLServerFormatSQLVisitorFacade.java
index ea625e2..157b988 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/format/facade/SQLServerFormatSQLVisitorFacade.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/format/facade/SQLServerFormatSQLVisitorFacade.java
@@ -17,46 +17,46 @@
package org.apache.shardingsphere.sql.parser.sqlserver.visitor.format.facade;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.facade.FormatSQLVisitorFacade;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DALFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DCLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DDLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DMLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.RLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.TCLFormatSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.format.SQLFormatVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DALSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DCLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DDLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DMLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.RLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.TCLSQLVisitor;
/**
* Format SQL Visitor facade for MySQL.
*/
-public final class SQLServerFormatSQLVisitorFacade implements FormatSQLVisitorFacade {
+public final class SQLServerFormatSQLVisitorFacade implements SQLFormatVisitorFacade {
@Override
- public Class<? extends DMLFormatSQLVisitor> getDMLVisitorClass() {
+ public Class<? extends DMLSQLVisitor> getDMLVisitorClass() {
throw new UnsupportedOperationException();
}
@Override
- public Class<? extends DDLFormatSQLVisitor> getDDLVisitorClass() {
+ public Class<? extends DDLSQLVisitor> getDDLVisitorClass() {
throw new UnsupportedOperationException();
}
@Override
- public Class<? extends TCLFormatSQLVisitor> getTCLVisitorClass() {
+ public Class<? extends TCLSQLVisitor> getTCLVisitorClass() {
throw new UnsupportedOperationException();
}
@Override
- public Class<? extends DCLFormatSQLVisitor> getDCLVisitorClass() {
+ public Class<? extends DCLSQLVisitor> getDCLVisitorClass() {
throw new UnsupportedOperationException();
}
@Override
- public Class<? extends DALFormatSQLVisitor> getDALVisitorClass() {
+ public Class<? extends DALSQLVisitor> getDALVisitorClass() {
throw new UnsupportedOperationException();
}
@Override
- public Class<? extends RLFormatSQLVisitor> getRLVisitorClass() {
+ public Class<? extends RLSQLVisitor> getRLVisitorClass() {
throw new UnsupportedOperationException();
}
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/facade/SQLServerStatementSQLVisitorFacade.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/facade/SQLServerStatementSQLVisitorFacade.java
index 35627c9..73a2e13 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/facade/SQLServerStatementSQLVisitorFacade.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/facade/SQLServerStatementSQLVisitorFacade.java
@@ -17,13 +17,13 @@
package org.apache.shardingsphere.sql.parser.sqlserver.visitor.statement.facade;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.facade.StatementSQLVisitorFacade;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DALStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DCLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DDLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DMLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.RLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.TCLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DALSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DCLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DDLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DMLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.RLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.TCLSQLVisitor;
import org.apache.shardingsphere.sql.parser.sqlserver.visitor.statement.impl.SQLServerDALStatementSQLVisitor;
import org.apache.shardingsphere.sql.parser.sqlserver.visitor.statement.impl.SQLServerDCLStatementSQLVisitor;
import org.apache.shardingsphere.sql.parser.sqlserver.visitor.statement.impl.SQLServerDDLStatementSQLVisitor;
@@ -33,35 +33,35 @@ import org.apache.shardingsphere.sql.parser.sqlserver.visitor.statement.impl.SQL
/**
* Statement SQL Visitor facade for SQLServer.
*/
-public final class SQLServerStatementSQLVisitorFacade implements StatementSQLVisitorFacade {
+public final class SQLServerStatementSQLVisitorFacade implements SQLStatementVisitorFacade {
@Override
- public Class<? extends DMLStatementSQLVisitor> getDMLVisitorClass() {
+ public Class<? extends DMLSQLVisitor> getDMLVisitorClass() {
return SQLServerDMLStatementSQLVisitor.class;
}
@Override
- public Class<? extends DDLStatementSQLVisitor> getDDLVisitorClass() {
+ public Class<? extends DDLSQLVisitor> getDDLVisitorClass() {
return SQLServerDDLStatementSQLVisitor.class;
}
@Override
- public Class<? extends TCLStatementSQLVisitor> getTCLVisitorClass() {
+ public Class<? extends TCLSQLVisitor> getTCLVisitorClass() {
return SQLServerTCLStatementSQLVisitor.class;
}
@Override
- public Class<? extends DCLStatementSQLVisitor> getDCLVisitorClass() {
+ public Class<? extends DCLSQLVisitor> getDCLVisitorClass() {
return SQLServerDCLStatementSQLVisitor.class;
}
@Override
- public Class<? extends DALStatementSQLVisitor> getDALVisitorClass() {
+ public Class<? extends DALSQLVisitor> getDALVisitorClass() {
return SQLServerDALStatementSQLVisitor.class;
}
@Override
- public Class<? extends RLStatementSQLVisitor> getRLVisitorClass() {
+ public Class<? extends RLSQLVisitor> getRLVisitorClass() {
return null;
}
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerDALStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerDALStatementSQLVisitor.java
index 2370a86..e806d33 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerDALStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerDALStatementSQLVisitor.java
@@ -17,10 +17,11 @@
package org.apache.shardingsphere.sql.parser.sqlserver.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DALStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DALSQLVisitor;
/**
* DAL Statement SQL visitor for SQLServer.
*/
-public final class SQLServerDALStatementSQLVisitor extends SQLServerStatementSQLVisitor implements DALStatementSQLVisitor {
+public final class SQLServerDALStatementSQLVisitor extends SQLServerStatementSQLVisitor implements DALSQLVisitor, SQLStatementVisitor {
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerDCLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerDCLStatementSQLVisitor.java
index aceefeb..3697c61 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerDCLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerDCLStatementSQLVisitor.java
@@ -17,8 +17,9 @@
package org.apache.shardingsphere.sql.parser.sqlserver.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DCLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DCLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.SQLServerStatementParser.AlterLoginContext;
import org.apache.shardingsphere.sql.parser.autogen.SQLServerStatementParser.AlterRoleContext;
import org.apache.shardingsphere.sql.parser.autogen.SQLServerStatementParser.AlterUserContext;
@@ -53,7 +54,7 @@ import java.util.Collections;
/**
* DCL Statement SQL visitor for SQLServer.
*/
-public final class SQLServerDCLStatementSQLVisitor extends SQLServerStatementSQLVisitor implements DCLStatementSQLVisitor {
+public final class SQLServerDCLStatementSQLVisitor extends SQLServerStatementSQLVisitor implements DCLSQLVisitor, SQLStatementVisitor {
@Override
public ASTNode visitGrant(final GrantContext ctx) {
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerDDLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerDDLStatementSQLVisitor.java
index 5f76a99..bc5236f 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerDDLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerDDLStatementSQLVisitor.java
@@ -17,8 +17,9 @@
package org.apache.shardingsphere.sql.parser.sqlserver.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DDLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DDLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.SQLServerStatementParser.AddColumnSpecificationContext;
import org.apache.shardingsphere.sql.parser.autogen.SQLServerStatementParser.AlterColumnAddOptionContext;
import org.apache.shardingsphere.sql.parser.autogen.SQLServerStatementParser.AlterDefinitionClauseContext;
@@ -65,7 +66,7 @@ import java.util.LinkedList;
/**
* DDL Statement SQL visitor for SQLServer.
*/
-public final class SQLServerDDLStatementSQLVisitor extends SQLServerStatementSQLVisitor implements DDLStatementSQLVisitor {
+public final class SQLServerDDLStatementSQLVisitor extends SQLServerStatementSQLVisitor implements DDLSQLVisitor, SQLStatementVisitor {
@SuppressWarnings("unchecked")
@Override
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerDMLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerDMLStatementSQLVisitor.java
index bf461b4..413e60d 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerDMLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerDMLStatementSQLVisitor.java
@@ -17,8 +17,9 @@
package org.apache.shardingsphere.sql.parser.sqlserver.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DMLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DMLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.SQLServerStatementParser.AggregationClauseContext;
import org.apache.shardingsphere.sql.parser.autogen.SQLServerStatementParser.AliasContext;
import org.apache.shardingsphere.sql.parser.autogen.SQLServerStatementParser.AssignmentContext;
@@ -122,7 +123,7 @@ import java.util.List;
/**
* DML Statement SQL visitor for SQLServer.
*/
-public final class SQLServerDMLStatementSQLVisitor extends SQLServerStatementSQLVisitor implements DMLStatementSQLVisitor {
+public final class SQLServerDMLStatementSQLVisitor extends SQLServerStatementSQLVisitor implements DMLSQLVisitor, SQLStatementVisitor {
@Override
public ASTNode visitInsert(final InsertContext ctx) {
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerStatementSQLVisitor.java
index 617e826..0fb5894 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerStatementSQLVisitor.java
@@ -22,7 +22,7 @@ import lombok.Getter;
import org.antlr.v4.runtime.ParserRuleContext;
import org.antlr.v4.runtime.misc.Interval;
import org.antlr.v4.runtime.tree.TerminalNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
import org.apache.shardingsphere.sql.parser.autogen.SQLServerStatementBaseVisitor;
import org.apache.shardingsphere.sql.parser.autogen.SQLServerStatementParser.AggregationFunctionContext;
import org.apache.shardingsphere.sql.parser.autogen.SQLServerStatementParser.BitExprContext;
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerTCLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerTCLStatementSQLVisitor.java
index 0367c93..60c3c99 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerTCLStatementSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-sqlserver/src/main/java/org/apache/shardingsphere/sql/parser/sqlserver/visitor/statement/impl/SQLServerTCLStatementSQLVisitor.java
@@ -17,8 +17,9 @@
package org.apache.shardingsphere.sql.parser.sqlserver.visitor.statement.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.TCLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.TCLSQLVisitor;
import org.apache.shardingsphere.sql.parser.autogen.SQLServerStatementParser.BeginTransactionContext;
import org.apache.shardingsphere.sql.parser.autogen.SQLServerStatementParser.CommitContext;
import org.apache.shardingsphere.sql.parser.autogen.SQLServerStatementParser.RollbackContext;
@@ -35,7 +36,7 @@ import org.apache.shardingsphere.sql.parser.sql.dialect.statement.sqlserver.tcl.
/**
* TCL Statement SQL visitor for SQLServer.
*/
-public final class SQLServerTCLStatementSQLVisitor extends SQLServerStatementSQLVisitor implements TCLStatementSQLVisitor {
+public final class SQLServerTCLStatementSQLVisitor extends SQLServerStatementSQLVisitor implements TCLSQLVisitor, SQLStatementVisitor {
@Override
public ASTNode visitSetTransaction(final SetTransactionContext ctx) {
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-engine/src/main/java/org/apache/shardingsphere/sql/parser/core/ParseASTNode.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-engine/src/main/java/org/apache/shardingsphere/sql/parser/core/ParseASTNode.java
index f89a162..6f2772e 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-engine/src/main/java/org/apache/shardingsphere/sql/parser/core/ParseASTNode.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-engine/src/main/java/org/apache/shardingsphere/sql/parser/core/ParseASTNode.java
@@ -19,7 +19,7 @@ package org.apache.shardingsphere.sql.parser.core;
import lombok.RequiredArgsConstructor;
import org.antlr.v4.runtime.tree.ParseTree;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
/**
* Parse AST node.
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/parser/SQLParser.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/parser/SQLParser.java
index da16151..7e89d4c 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/parser/SQLParser.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/parser/SQLParser.java
@@ -17,7 +17,7 @@
package org.apache.shardingsphere.sql.parser.api.parser;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
/**
* SQL parser.
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/ASTNode.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/ASTNode.java
similarity index 92%
copy from shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/ASTNode.java
copy to shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/ASTNode.java
index 76a5ad3..71d89b2 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/ASTNode.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/ASTNode.java
@@ -15,7 +15,7 @@
* limitations under the License.
*/
-package org.apache.shardingsphere.sql.parser.api.visitor.statement;
+package org.apache.shardingsphere.sql.parser.api.visitor;
/**
* AST node.
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/SQLVisitorFacadeFactory.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/SQLVisitorFacadeFactory.java
index 274401e..fc01a5c 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/SQLVisitorFacadeFactory.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/SQLVisitorFacadeFactory.java
@@ -17,8 +17,8 @@
package org.apache.shardingsphere.sql.parser.api.visitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.facade.FormatSQLVisitorFacade;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.facade.StatementSQLVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.format.SQLFormatVisitorFacade;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.statement.SQLStatementVisitorFacade;
/**
* SQL visitor facade engine.
@@ -30,12 +30,12 @@ public interface SQLVisitorFacadeFactory {
*
* @return DML visitor class
*/
- Class<? extends StatementSQLVisitorFacade> getStatementSQLVisitorFacadeClass();
+ Class<? extends SQLStatementVisitorFacade> getStatementSQLVisitorFacadeClass();
/**
* Get format visitor facade class.
*
* @return DDL visitor class
*/
- Class<? extends FormatSQLVisitorFacade> getFormatSQLVisitorFacadeClass();
+ Class<? extends SQLFormatVisitorFacade> getFormatSQLVisitorFacadeClass();
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/TCLFormatSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/TCLFormatSQLVisitor.java
deleted file mode 100644
index 0c47bf8..0000000
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/TCLFormatSQLVisitor.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.shardingsphere.sql.parser.api.visitor.format.impl;
-
-import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitor;
-
-/**
- * TCL format SQL visitor.
- */
-public interface TCLFormatSQLVisitor extends SQLVisitor {
-}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/RLFormatSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/operation/SQLOperationVisitor.java
similarity index 85%
copy from shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/RLFormatSQLVisitor.java
copy to shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/operation/SQLOperationVisitor.java
index b924b4d..c07cc8e 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/RLFormatSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/operation/SQLOperationVisitor.java
@@ -15,12 +15,12 @@
* limitations under the License.
*/
-package org.apache.shardingsphere.sql.parser.api.visitor.format.impl;
+package org.apache.shardingsphere.sql.parser.api.visitor.operation;
import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitor;
/**
- * RL format SQL visitor.
+ * SQL operation visitor.
*/
-public interface RLFormatSQLVisitor extends SQLVisitor {
+public interface SQLOperationVisitor extends SQLVisitor {
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/DDLFormatSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/operation/format/SQLFormatVisitor.java
similarity index 76%
copy from shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/DDLFormatSQLVisitor.java
copy to shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/operation/format/SQLFormatVisitor.java
index d122c47..9a2f31e 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/DDLFormatSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/operation/format/SQLFormatVisitor.java
@@ -15,12 +15,12 @@
* limitations under the License.
*/
-package org.apache.shardingsphere.sql.parser.api.visitor.format.impl;
+package org.apache.shardingsphere.sql.parser.api.visitor.operation.format;
-import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.SQLOperationVisitor;
/**
- * DDL format SQL visitor.
+ * SQL format visitor.
*/
-public interface DDLFormatSQLVisitor extends SQLVisitor {
+public interface SQLFormatVisitor extends SQLOperationVisitor {
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/facade/FormatSQLVisitorFacade.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/operation/format/SQLFormatVisitorFacade.java
similarity index 57%
rename from shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/facade/FormatSQLVisitorFacade.java
rename to shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/operation/format/SQLFormatVisitorFacade.java
index 85768b0..6c086f1 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/facade/FormatSQLVisitorFacade.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/operation/format/SQLFormatVisitorFacade.java
@@ -15,60 +15,60 @@
* limitations under the License.
*/
-package org.apache.shardingsphere.sql.parser.api.visitor.format.facade;
+package org.apache.shardingsphere.sql.parser.api.visitor.operation.format;
import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitorFacade;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DALFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DCLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DDLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.DMLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.RLFormatSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.format.impl.TCLFormatSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DALSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DCLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DDLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DMLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.RLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.TCLSQLVisitor;
/**
- * Format SQL visitor facade.
+ * SQL format visitor facade.
*/
-public interface FormatSQLVisitorFacade extends SQLVisitorFacade {
+public interface SQLFormatVisitorFacade extends SQLVisitorFacade {
/**
* Get DML visitor class.
*
* @return DML visitor class
*/
- Class<? extends DMLFormatSQLVisitor> getDMLVisitorClass();
+ Class<? extends DMLSQLVisitor> getDMLVisitorClass();
/**
* Get DDL visitor class.
*
* @return DDL visitor class
*/
- Class<? extends DDLFormatSQLVisitor> getDDLVisitorClass();
+ Class<? extends DDLSQLVisitor> getDDLVisitorClass();
/**
* Get TCL visitor class.
*
* @return TCL visitor class
*/
- Class<? extends TCLFormatSQLVisitor> getTCLVisitorClass();
+ Class<? extends TCLSQLVisitor> getTCLVisitorClass();
/**
* Get DCL visitor class.
*
* @return DCL visitor class
*/
- Class<? extends DCLFormatSQLVisitor> getDCLVisitorClass();
+ Class<? extends DCLSQLVisitor> getDCLVisitorClass();
/**
* Get DAL visitor class.
*
* @return DAL visitor class
*/
- Class<? extends DALFormatSQLVisitor> getDALVisitorClass();
+ Class<? extends DALSQLVisitor> getDALVisitorClass();
/**
* Get RL visitor class.
*
* @return RL visitor class
*/
- Class<? extends RLFormatSQLVisitor> getRLVisitorClass();
+ Class<? extends RLSQLVisitor> getRLVisitorClass();
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/DDLFormatSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/operation/statement/SQLStatementVisitor.java
similarity index 75%
rename from shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/DDLFormatSQLVisitor.java
rename to shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/operation/statement/SQLStatementVisitor.java
index d122c47..5e1a016 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/DDLFormatSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/operation/statement/SQLStatementVisitor.java
@@ -15,12 +15,12 @@
* limitations under the License.
*/
-package org.apache.shardingsphere.sql.parser.api.visitor.format.impl;
+package org.apache.shardingsphere.sql.parser.api.visitor.operation.statement;
-import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.operation.SQLOperationVisitor;
/**
- * DDL format SQL visitor.
+ * SQL statement visitor.
*/
-public interface DDLFormatSQLVisitor extends SQLVisitor {
+public interface SQLStatementVisitor extends SQLOperationVisitor {
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/facade/StatementSQLVisitorFacade.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/operation/statement/SQLStatementVisitorFacade.java
similarity index 55%
rename from shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/facade/StatementSQLVisitorFacade.java
rename to shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/operation/statement/SQLStatementVisitorFacade.java
index 96d05d1..987370c 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/facade/StatementSQLVisitorFacade.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/operation/statement/SQLStatementVisitorFacade.java
@@ -15,60 +15,60 @@
* limitations under the License.
*/
-package org.apache.shardingsphere.sql.parser.api.visitor.statement.facade;
+package org.apache.shardingsphere.sql.parser.api.visitor.operation.statement;
import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitorFacade;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DALStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DCLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DDLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.DMLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.RLStatementSQLVisitor;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.impl.TCLStatementSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DALSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DCLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DDLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.DMLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.RLSQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.impl.TCLSQLVisitor;
/**
- * Statement SQL visitor facade.
+ * SQL statement visitor facade.
*/
-public interface StatementSQLVisitorFacade extends SQLVisitorFacade {
+public interface SQLStatementVisitorFacade extends SQLVisitorFacade {
/**
* Get DML visitor class.
*
* @return DML visitor class
*/
- Class<? extends DMLStatementSQLVisitor> getDMLVisitorClass();
+ Class<? extends DMLSQLVisitor> getDMLVisitorClass();
/**
* Get DDL visitor class.
*
* @return DDL visitor class
*/
- Class<? extends DDLStatementSQLVisitor> getDDLVisitorClass();
+ Class<? extends DDLSQLVisitor> getDDLVisitorClass();
/**
* Get TCL visitor class.
*
* @return TCL visitor class
*/
- Class<? extends TCLStatementSQLVisitor> getTCLVisitorClass();
+ Class<? extends TCLSQLVisitor> getTCLVisitorClass();
/**
* Get DCL visitor class.
*
* @return DCL visitor class
*/
- Class<? extends DCLStatementSQLVisitor> getDCLVisitorClass();
+ Class<? extends DCLSQLVisitor> getDCLVisitorClass();
/**
* Get DAL visitor class.
*
* @return DAL visitor class
*/
- Class<? extends DALStatementSQLVisitor> getDALVisitorClass();
+ Class<? extends DALSQLVisitor> getDALVisitorClass();
/**
* Get RL visitor class.
*
* @return RL visitor class
*/
- Class<? extends RLStatementSQLVisitor> getRLVisitorClass();
+ Class<? extends RLSQLVisitor> getRLVisitorClass();
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/impl/DALStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/impl/DALStatementSQLVisitor.java
deleted file mode 100644
index 66c3630..0000000
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/impl/DALStatementSQLVisitor.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.shardingsphere.sql.parser.api.visitor.statement.impl;
-
-import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitor;
-
-/**
- * DAL statement SQL visitor.
- */
-public interface DALStatementSQLVisitor extends SQLVisitor {
-}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/impl/DCLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/impl/DCLStatementSQLVisitor.java
deleted file mode 100644
index cae301e..0000000
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/impl/DCLStatementSQLVisitor.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.shardingsphere.sql.parser.api.visitor.statement.impl;
-
-import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitor;
-
-/**
- * DCL statement SQL visitor.
- */
-public interface DCLStatementSQLVisitor extends SQLVisitor {
-}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/impl/DDLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/impl/DDLStatementSQLVisitor.java
deleted file mode 100644
index 7b362de..0000000
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/impl/DDLStatementSQLVisitor.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.shardingsphere.sql.parser.api.visitor.statement.impl;
-
-import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitor;
-
-/**
- * DDL statement SQL visitor.
- */
-public interface DDLStatementSQLVisitor extends SQLVisitor {
-}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/impl/DMLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/impl/DMLStatementSQLVisitor.java
deleted file mode 100644
index 71cc8b5..0000000
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/impl/DMLStatementSQLVisitor.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.shardingsphere.sql.parser.api.visitor.statement.impl;
-
-import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitor;
-
-/**
- * DML statement SQL visitor.
- */
-public interface DMLStatementSQLVisitor extends SQLVisitor {
-}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/impl/RLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/impl/RLStatementSQLVisitor.java
deleted file mode 100644
index b98be40..0000000
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/impl/RLStatementSQLVisitor.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.shardingsphere.sql.parser.api.visitor.statement.impl;
-
-import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitor;
-
-/**
- * RL statement SQL visitor.
- */
-public interface RLStatementSQLVisitor extends SQLVisitor {
-}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/impl/TCLStatementSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/impl/TCLStatementSQLVisitor.java
deleted file mode 100644
index 8fd783a..0000000
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/impl/TCLStatementSQLVisitor.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.shardingsphere.sql.parser.api.visitor.statement.impl;
-
-import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitor;
-
-/**
- * TCL statement SQL visitor.
- */
-public interface TCLStatementSQLVisitor extends SQLVisitor {
-}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/DMLFormatSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/SQLTypeVisitor.java
similarity index 85%
rename from shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/DMLFormatSQLVisitor.java
rename to shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/SQLTypeVisitor.java
index 3cdd1ed..952e380 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/DMLFormatSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/SQLTypeVisitor.java
@@ -15,12 +15,12 @@
* limitations under the License.
*/
-package org.apache.shardingsphere.sql.parser.api.visitor.format.impl;
+package org.apache.shardingsphere.sql.parser.api.visitor.type;
import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitor;
/**
- * DML format SQL visitor.
+ * SQL type visitor.
*/
-public interface DMLFormatSQLVisitor extends SQLVisitor {
+public interface SQLTypeVisitor extends SQLVisitor {
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/DALFormatSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/impl/DALSQLVisitor.java
similarity index 78%
rename from shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/DALFormatSQLVisitor.java
rename to shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/impl/DALSQLVisitor.java
index 317cf2f..f13af6b 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/DALFormatSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/impl/DALSQLVisitor.java
@@ -15,12 +15,12 @@
* limitations under the License.
*/
-package org.apache.shardingsphere.sql.parser.api.visitor.format.impl;
+package org.apache.shardingsphere.sql.parser.api.visitor.type.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.SQLTypeVisitor;
/**
- * DAL format SQL visitor.
+ * DAL SQL visitor.
*/
-public interface DALFormatSQLVisitor extends SQLVisitor {
+public interface DALSQLVisitor extends SQLTypeVisitor {
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/DCLFormatSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/impl/DCLSQLVisitor.java
similarity index 78%
rename from shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/DCLFormatSQLVisitor.java
rename to shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/impl/DCLSQLVisitor.java
index 6777efb..f55667d 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/DCLFormatSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/impl/DCLSQLVisitor.java
@@ -15,12 +15,12 @@
* limitations under the License.
*/
-package org.apache.shardingsphere.sql.parser.api.visitor.format.impl;
+package org.apache.shardingsphere.sql.parser.api.visitor.type.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.SQLTypeVisitor;
/**
- * DCL format SQL visitor.
+ * DCL SQL visitor.
*/
-public interface DCLFormatSQLVisitor extends SQLVisitor {
+public interface DCLSQLVisitor extends SQLTypeVisitor {
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/RLFormatSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/impl/DDLSQLVisitor.java
similarity index 78%
copy from shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/RLFormatSQLVisitor.java
copy to shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/impl/DDLSQLVisitor.java
index b924b4d..b532ebb 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/RLFormatSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/impl/DDLSQLVisitor.java
@@ -15,12 +15,12 @@
* limitations under the License.
*/
-package org.apache.shardingsphere.sql.parser.api.visitor.format.impl;
+package org.apache.shardingsphere.sql.parser.api.visitor.type.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.SQLTypeVisitor;
/**
- * RL format SQL visitor.
+ * DDL SQL visitor.
*/
-public interface RLFormatSQLVisitor extends SQLVisitor {
+public interface DDLSQLVisitor extends SQLTypeVisitor {
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/RLFormatSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/impl/DMLSQLVisitor.java
similarity index 78%
copy from shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/RLFormatSQLVisitor.java
copy to shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/impl/DMLSQLVisitor.java
index b924b4d..4907f11 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/RLFormatSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/impl/DMLSQLVisitor.java
@@ -15,12 +15,12 @@
* limitations under the License.
*/
-package org.apache.shardingsphere.sql.parser.api.visitor.format.impl;
+package org.apache.shardingsphere.sql.parser.api.visitor.type.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.SQLTypeVisitor;
/**
- * RL format SQL visitor.
+ * DML SQL visitor.
*/
-public interface RLFormatSQLVisitor extends SQLVisitor {
+public interface DMLSQLVisitor extends SQLTypeVisitor {
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/ASTNode.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/impl/RLSQLVisitor.java
similarity index 78%
rename from shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/ASTNode.java
rename to shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/impl/RLSQLVisitor.java
index 76a5ad3..ed93332 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/ASTNode.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/impl/RLSQLVisitor.java
@@ -15,10 +15,12 @@
* limitations under the License.
*/
-package org.apache.shardingsphere.sql.parser.api.visitor.statement;
+package org.apache.shardingsphere.sql.parser.api.visitor.type.impl;
+
+import org.apache.shardingsphere.sql.parser.api.visitor.type.SQLTypeVisitor;
/**
- * AST node.
+ * RL SQL visitor.
*/
-public interface ASTNode {
+public interface RLSQLVisitor extends SQLTypeVisitor {
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/RLFormatSQLVisitor.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/impl/TCLSQLVisitor.java
similarity index 78%
rename from shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/RLFormatSQLVisitor.java
rename to shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/impl/TCLSQLVisitor.java
index b924b4d..a9a7613 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/format/impl/RLFormatSQLVisitor.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/type/impl/TCLSQLVisitor.java
@@ -15,12 +15,12 @@
* limitations under the License.
*/
-package org.apache.shardingsphere.sql.parser.api.visitor.format.impl;
+package org.apache.shardingsphere.sql.parser.api.visitor.type.impl;
-import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitor;
+import org.apache.shardingsphere.sql.parser.api.visitor.type.SQLTypeVisitor;
/**
- * RL format SQL visitor.
+ * TCL SQL visitor.
*/
-public interface RLFormatSQLVisitor extends SQLVisitor {
+public interface TCLSQLVisitor extends SQLTypeVisitor {
}
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-statement/src/main/java/org/apache/shardingsphere/sql/parser/sql/common/segment/SQLSegment.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-statement/src/main/java/org/apache/shardingsphere/sql/parser/sql/common/segment/SQLSegment.java
index d641bd8..c4d0e28 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-statement/src/main/java/org/apache/shardingsphere/sql/parser/sql/common/segment/SQLSegment.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-statement/src/main/java/org/apache/shardingsphere/sql/parser/sql/common/segment/SQLSegment.java
@@ -17,7 +17,7 @@
package org.apache.shardingsphere.sql.parser.sql.common.segment;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
/**
* SQL segment.
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-statement/src/main/java/org/apache/shardingsphere/sql/parser/sql/common/statement/SQLStatement.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-statement/src/main/java/org/apache/shardingsphere/sql/parser/sql/common/statement/SQLStatement.java
index 210b8ef..547c953 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-statement/src/main/java/org/apache/shardingsphere/sql/parser/sql/common/statement/SQLStatement.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-statement/src/main/java/org/apache/shardingsphere/sql/parser/sql/common/statement/SQLStatement.java
@@ -17,7 +17,7 @@
package org.apache.shardingsphere.sql.parser.sql.common.statement;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
/**
* SQL statement.
diff --git a/shardingsphere-sql-parser/shardingsphere-sql-parser-statement/src/main/java/org/apache/shardingsphere/sql/parser/sql/common/value/ValueASTNode.java b/shardingsphere-sql-parser/shardingsphere-sql-parser-statement/src/main/java/org/apache/shardingsphere/sql/parser/sql/common/value/ValueASTNode.java
index 00439f7..e954e93 100644
--- a/shardingsphere-sql-parser/shardingsphere-sql-parser-statement/src/main/java/org/apache/shardingsphere/sql/parser/sql/common/value/ValueASTNode.java
+++ b/shardingsphere-sql-parser/shardingsphere-sql-parser-statement/src/main/java/org/apache/shardingsphere/sql/parser/sql/common/value/ValueASTNode.java
@@ -17,7 +17,7 @@
package org.apache.shardingsphere.sql.parser.sql.common.value;
-import org.apache.shardingsphere.sql.parser.api.visitor.statement.ASTNode;
+import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
/**
* Value AST node.