Package org.apache.calcite.sql.test
Class SqlTestFactory
java.lang.Object
org.apache.calcite.sql.test.SqlTestFactory
As
SqlTestFactory
but has no state, and therefore
configuration is passed to each method.-
Nested Class Summary
Modifier and TypeClassDescriptionstatic interface
Creates aSqlValidatorCatalogReader
for tests.static interface
Creates aRelOptPlanner
for tests.static interface
Creates aRelDataTypeFactory
for tests.static interface
CreatesSqlValidator
for tests. -
Field Summary
Modifier and TypeFieldDescriptionfinal ConnectionFactory
static final SqlTestFactory
final SqlToRelConverter.Config
final UnaryOperator<RelDataTypeSystem>
final SqlValidator.Config
-
Constructor Summary
ModifierConstructorDescriptionprotected
SqlTestFactory
(SqlTestFactory.CatalogReaderFactory catalogReaderFactory, SqlTestFactory.TypeFactoryFactory typeFactoryFactory, SqlTestFactory.PlannerFactory plannerFactory, Context plannerContext, UnaryOperator<RelOptCluster> clusterTransform, SqlTestFactory.ValidatorFactory validatorFactory, ConnectionFactory connectionFactory, SqlParser.Config parserConfig, SqlValidator.Config validatorConfig, SqlToRelConverter.Config sqlToRelConfig, SqlOperatorTable operatorTable, UnaryOperator<RelDataTypeSystem> typeSystemTransform) -
Method Summary
Modifier and TypeMethodDescriptioncreateParser
(String sql) Creates a parser.Creates a validator.withCatalogReader
(SqlTestFactory.CatalogReaderFactory catalogReaderFactory) withCluster
(UnaryOperator<RelOptCluster> transform) withConnectionFactory
(UnaryOperator<ConnectionFactory> transform) withOperatorTable
(UnaryOperator<SqlOperatorTable> transform) withParserConfig
(UnaryOperator<SqlParser.Config> transform) withPlannerContext
(UnaryOperator<Context> transform) withPlannerFactory
(SqlTestFactory.PlannerFactory plannerFactory) withSqlToRelConfig
(UnaryOperator<SqlToRelConverter.Config> transform) withTypeFactoryFactory
(SqlTestFactory.TypeFactoryFactory typeFactoryFactory) withTypeSystem
(UnaryOperator<RelDataTypeSystem> typeSystemTransform) withValidator
(SqlTestFactory.ValidatorFactory validatorFactory) withValidatorConfig
(UnaryOperator<SqlValidator.Config> transform)
-
Field Details
-
INSTANCE
-
connectionFactory
-
typeFactoryFactory
-
validatorConfig
-
sqlToRelConfig
-
typeSystemTransform
-
-
Constructor Details
-
SqlTestFactory
protected SqlTestFactory(SqlTestFactory.CatalogReaderFactory catalogReaderFactory, SqlTestFactory.TypeFactoryFactory typeFactoryFactory, SqlTestFactory.PlannerFactory plannerFactory, Context plannerContext, UnaryOperator<RelOptCluster> clusterTransform, SqlTestFactory.ValidatorFactory validatorFactory, ConnectionFactory connectionFactory, SqlParser.Config parserConfig, SqlValidator.Config validatorConfig, SqlToRelConverter.Config sqlToRelConfig, SqlOperatorTable operatorTable, UnaryOperator<RelDataTypeSystem> typeSystemTransform)
-
-
Method Details
-
createParser
Creates a parser. -
createValidator
Creates a validator. -
createAdvisor
-
withTypeFactoryFactory
-
withTypeSystem
-
withPlannerFactory
-
withPlannerContext
-
withCluster
-
withCatalogReader
-
withValidator
-
withValidatorConfig
-
withSqlToRelConfig
-
withParserConfig
-
withConnectionFactory
-
withOperatorTable
-
parserConfig
-
getTypeFactory
-
createSqlToRelConverter
-