Interface FilterEvaluator
- All Known Implementing Classes:
FilterEvaluator.InfoSchemaFilterEvaluator
,FilterEvaluator.NoFilterEvaluator
public interface FilterEvaluator
Evaluates information schema for the given condition.
Evaluation can be done with or without filter.
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic class
Evaluates necessity to visit certain type of information_schema data using provided filter.static class
Evaluates necessity to visit certain type of information_schema data based on given schema type. -
Method Summary
Modifier and TypeMethodDescriptionboolean
shouldPruneSchema
(String schemaName) Prune the given schema.boolean
Visit the catalog.boolean
shouldVisitColumn
(String schemaName, String tableName, String columnName) Visit the columns in the given schema and table.boolean
shouldVisitFiles
(String schemaName, org.apache.calcite.schema.SchemaPlus schema) Visit the files in the given schema.boolean
shouldVisitSchema
(String schemaName, org.apache.calcite.schema.SchemaPlus schema) Visit the given schema.boolean
shouldVisitTable
(String schemaName, String tableName, org.apache.calcite.schema.Schema.TableType tableType) Visit the tables in the given schema.
-
Method Details
-
shouldVisitCatalog
boolean shouldVisitCatalog()Visit the catalog. Drill has only one catalog.- Returns:
- whether to continue exploring the contents of the catalog or not. Contents are schema/schema tree.
-
shouldPruneSchema
Prune the given schema.- Parameters:
schemaName
- name of the schemaschema
- schema object- Returns:
- whether to prune this schema and all its descendants from the search tree.
-
shouldVisitSchema
Visit the given schema.- Parameters:
schemaName
- name of the schemaschema
- schema object- Returns:
- whether to continue exploring the contents of the schema or not. Contents are tables within the schema.
-
shouldVisitTable
boolean shouldVisitTable(String schemaName, String tableName, org.apache.calcite.schema.Schema.TableType tableType) Visit the tables in the given schema.- Parameters:
schemaName
- name of the schematableName
- name of the tabletableType
- type of the table- Returns:
- whether to continue exploring the contents of the table or not. Contents are tables attributes and columns.
-
shouldVisitColumn
Visit the columns in the given schema and table.- Parameters:
schemaName
- name of the schematableName
- name of the tablecolumnName
- type of the table- Returns:
- whether to continue exploring the contents of the column or not. Contents are columns attributes.
-
shouldVisitFiles
Visit the files in the given schema.- Parameters:
schemaName
- name of the schemaschema
- schema object- Returns:
- whether to continue exploring the files in the schema
-