From 0626ef53729ead1ce7c3a990fcbd09dacfa850c5 Mon Sep 17 00:00:00 2001 From: Damian Guy Date: Tue, 23 Jan 2018 16:35:02 -0800 Subject: [PATCH] avoid star import --- checkstyle/suppressions.xml | 1 - .../ksql/util/ExpressionTypeManager.java | 16 ++- .../io/confluent/ksql/parser/AstBuilder.java | 100 +++++++++++++++++- 3 files changed, 114 insertions(+), 3 deletions(-) diff --git a/checkstyle/suppressions.xml b/checkstyle/suppressions.xml index b6e5206554bf..15ba71c17092 100644 --- a/checkstyle/suppressions.xml +++ b/checkstyle/suppressions.xml @@ -15,7 +15,6 @@ - diff --git a/ksql-engine/src/main/java/io/confluent/ksql/util/ExpressionTypeManager.java b/ksql-engine/src/main/java/io/confluent/ksql/util/ExpressionTypeManager.java index 66ae0699d761..1751c3175a73 100644 --- a/ksql-engine/src/main/java/io/confluent/ksql/util/ExpressionTypeManager.java +++ b/ksql-engine/src/main/java/io/confluent/ksql/util/ExpressionTypeManager.java @@ -19,8 +19,22 @@ import io.confluent.ksql.function.FunctionRegistry; import io.confluent.ksql.function.KsqlAggregateFunction; import io.confluent.ksql.function.KsqlFunction; +import io.confluent.ksql.parser.tree.ArithmeticBinaryExpression; +import io.confluent.ksql.parser.tree.BooleanLiteral; +import io.confluent.ksql.parser.tree.Cast; +import io.confluent.ksql.parser.tree.ComparisonExpression; import io.confluent.ksql.parser.tree.DefaultAstVisitor; -import io.confluent.ksql.parser.tree.*; +import io.confluent.ksql.parser.tree.DereferenceExpression; +import io.confluent.ksql.parser.tree.DoubleLiteral; +import io.confluent.ksql.parser.tree.Expression; +import io.confluent.ksql.parser.tree.FunctionCall; +import io.confluent.ksql.parser.tree.IsNotNullPredicate; +import io.confluent.ksql.parser.tree.IsNullPredicate; +import io.confluent.ksql.parser.tree.LikePredicate; +import io.confluent.ksql.parser.tree.LongLiteral; +import io.confluent.ksql.parser.tree.QualifiedNameReference; +import io.confluent.ksql.parser.tree.StringLiteral; +import io.confluent.ksql.parser.tree.SubscriptExpression; import io.confluent.ksql.planner.PlanException; import org.apache.kafka.connect.data.Field; import org.apache.kafka.connect.data.Schema; diff --git a/ksql-parser/src/main/java/io/confluent/ksql/parser/AstBuilder.java b/ksql-parser/src/main/java/io/confluent/ksql/parser/AstBuilder.java index ebe85cf6f9fe..44b0304b23dc 100644 --- a/ksql-parser/src/main/java/io/confluent/ksql/parser/AstBuilder.java +++ b/ksql-parser/src/main/java/io/confluent/ksql/parser/AstBuilder.java @@ -39,7 +39,105 @@ import io.confluent.ksql.metastore.StructuredDataSource; import io.confluent.ksql.parser.SqlBaseParser.TablePropertiesContext; import io.confluent.ksql.parser.SqlBaseParser.TablePropertyContext; -import io.confluent.ksql.parser.tree.*; +import io.confluent.ksql.parser.tree.AliasedRelation; +import io.confluent.ksql.parser.tree.AllColumns; +import io.confluent.ksql.parser.tree.ArithmeticBinaryExpression; +import io.confluent.ksql.parser.tree.ArithmeticUnaryExpression; +import io.confluent.ksql.parser.tree.BetweenPredicate; +import io.confluent.ksql.parser.tree.BinaryLiteral; +import io.confluent.ksql.parser.tree.BooleanLiteral; +import io.confluent.ksql.parser.tree.Cast; +import io.confluent.ksql.parser.tree.ComparisonExpression; +import io.confluent.ksql.parser.tree.CreateStream; +import io.confluent.ksql.parser.tree.CreateStreamAsSelect; +import io.confluent.ksql.parser.tree.CreateTable; +import io.confluent.ksql.parser.tree.CreateTableAsSelect; +import io.confluent.ksql.parser.tree.DecimalLiteral; +import io.confluent.ksql.parser.tree.DereferenceExpression; +import io.confluent.ksql.parser.tree.DoubleLiteral; +import io.confluent.ksql.parser.tree.DropStream; +import io.confluent.ksql.parser.tree.DropTable; +import io.confluent.ksql.parser.tree.DropTopic; +import io.confluent.ksql.parser.tree.Except; +import io.confluent.ksql.parser.tree.ExistsPredicate; +import io.confluent.ksql.parser.tree.Explain; +import io.confluent.ksql.parser.tree.ExplainFormat; +import io.confluent.ksql.parser.tree.ExplainType; +import io.confluent.ksql.parser.tree.ExportCatalog; +import io.confluent.ksql.parser.tree.Expression; +import io.confluent.ksql.parser.tree.Extract; +import io.confluent.ksql.parser.tree.FunctionCall; +import io.confluent.ksql.parser.tree.GenericLiteral; +import io.confluent.ksql.parser.tree.GroupBy; +import io.confluent.ksql.parser.tree.GroupingElement; +import io.confluent.ksql.parser.tree.GroupingSets; +import io.confluent.ksql.parser.tree.HoppingWindowExpression; +import io.confluent.ksql.parser.tree.InListExpression; +import io.confluent.ksql.parser.tree.InPredicate; +import io.confluent.ksql.parser.tree.Intersect; +import io.confluent.ksql.parser.tree.IntervalLiteral; +import io.confluent.ksql.parser.tree.IsNotNullPredicate; +import io.confluent.ksql.parser.tree.IsNullPredicate; +import io.confluent.ksql.parser.tree.Join; +import io.confluent.ksql.parser.tree.JoinCriteria; +import io.confluent.ksql.parser.tree.JoinOn; +import io.confluent.ksql.parser.tree.JoinUsing; +import io.confluent.ksql.parser.tree.LambdaExpression; +import io.confluent.ksql.parser.tree.LikePredicate; +import io.confluent.ksql.parser.tree.ListProperties; +import io.confluent.ksql.parser.tree.ListQueries; +import io.confluent.ksql.parser.tree.ListRegisteredTopics; +import io.confluent.ksql.parser.tree.ListStreams; +import io.confluent.ksql.parser.tree.ListTables; +import io.confluent.ksql.parser.tree.ListTopics; +import io.confluent.ksql.parser.tree.LogicalBinaryExpression; +import io.confluent.ksql.parser.tree.LongLiteral; +import io.confluent.ksql.parser.tree.NaturalJoin; +import io.confluent.ksql.parser.tree.Node; +import io.confluent.ksql.parser.tree.NodeLocation; +import io.confluent.ksql.parser.tree.NotExpression; +import io.confluent.ksql.parser.tree.NullIfExpression; +import io.confluent.ksql.parser.tree.NullLiteral; +import io.confluent.ksql.parser.tree.PrintTopic; +import io.confluent.ksql.parser.tree.QualifiedName; +import io.confluent.ksql.parser.tree.QualifiedNameReference; +import io.confluent.ksql.parser.tree.Query; +import io.confluent.ksql.parser.tree.QueryBody; +import io.confluent.ksql.parser.tree.QuerySpecification; +import io.confluent.ksql.parser.tree.RegisterTopic; +import io.confluent.ksql.parser.tree.Relation; +import io.confluent.ksql.parser.tree.Row; +import io.confluent.ksql.parser.tree.RunScript; +import io.confluent.ksql.parser.tree.SearchedCaseExpression; +import io.confluent.ksql.parser.tree.Select; +import io.confluent.ksql.parser.tree.SelectItem; +import io.confluent.ksql.parser.tree.SessionWindowExpression; +import io.confluent.ksql.parser.tree.SetProperty; +import io.confluent.ksql.parser.tree.ShowColumns; +import io.confluent.ksql.parser.tree.SimpleCaseExpression; +import io.confluent.ksql.parser.tree.SimpleGroupBy; +import io.confluent.ksql.parser.tree.SingleColumn; +import io.confluent.ksql.parser.tree.SortItem; +import io.confluent.ksql.parser.tree.Statement; +import io.confluent.ksql.parser.tree.Statements; +import io.confluent.ksql.parser.tree.StringLiteral; +import io.confluent.ksql.parser.tree.SubqueryExpression; +import io.confluent.ksql.parser.tree.SubscriptExpression; +import io.confluent.ksql.parser.tree.Table; +import io.confluent.ksql.parser.tree.TableElement; +import io.confluent.ksql.parser.tree.TableSubquery; +import io.confluent.ksql.parser.tree.TerminateQuery; +import io.confluent.ksql.parser.tree.TimeLiteral; +import io.confluent.ksql.parser.tree.TimestampLiteral; +import io.confluent.ksql.parser.tree.TumblingWindowExpression; +import io.confluent.ksql.parser.tree.Union; +import io.confluent.ksql.parser.tree.UnsetProperty; +import io.confluent.ksql.parser.tree.Values; +import io.confluent.ksql.parser.tree.WhenClause; +import io.confluent.ksql.parser.tree.Window; +import io.confluent.ksql.parser.tree.WindowExpression; +import io.confluent.ksql.parser.tree.With; +import io.confluent.ksql.parser.tree.WithQuery; import io.confluent.ksql.util.DataSourceExtractor; import io.confluent.ksql.util.KsqlException;