Package org.apache.calcite.adapter.csv
Class CsvTranslatableTable
java.lang.Object
org.apache.calcite.schema.impl.AbstractTable
org.apache.calcite.adapter.csv.CsvTable
org.apache.calcite.adapter.csv.CsvTranslatableTable
- All Implemented Interfaces:
QueryableTable
,Table
,TranslatableTable
,Wrapper
Table based on a CSV file.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.calcite.adapter.csv.CsvTable
CsvTable.Flavor
-
Field Summary
Fields inherited from class org.apache.calcite.adapter.csv.CsvTable
protoRowType, source
-
Method Summary
Modifier and TypeMethodDescription<T> Queryable<T>
asQueryable
(QueryProvider queryProvider, SchemaPlus schema, String tableName) Converts this table into aQueryable
.Returns the element type of the collection that will implement this table.getExpression
(SchemaPlus schema, String tableName, Class clazz) Generates an expression with which this table can be referenced in generated code.project
(DataContext root, int[] fields) Returns an enumerable over a given projection of the fields.toRel
(RelOptTable.ToRelContext context, RelOptTable relOptTable) Converts this table into arelational expression
.toString()
Methods inherited from class org.apache.calcite.adapter.csv.CsvTable
getFieldTypes, getRowType, isStream
Methods inherited from class org.apache.calcite.schema.impl.AbstractTable
getJdbcTableType, getStatistic, isRolledUp, rolledUpColumnValidInsideAgg, unwrap
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.apache.calcite.schema.Table
getJdbcTableType, getRowType, getStatistic, isRolledUp, rolledUpColumnValidInsideAgg
Methods inherited from interface org.apache.calcite.schema.Wrapper
maybeUnwrap, unwrapOrThrow
-
Method Details
-
toString
-
project
Returns an enumerable over a given projection of the fields. -
getExpression
Description copied from interface:QueryableTable
Generates an expression with which this table can be referenced in generated code.- Specified by:
getExpression
in interfaceQueryableTable
- Parameters:
schema
- SchematableName
- Table name (unique within schema)clazz
- The desired collection class; for exampleQueryable
.
-
getElementType
Description copied from interface:QueryableTable
Returns the element type of the collection that will implement this table.- Specified by:
getElementType
in interfaceQueryableTable
-
asQueryable
public <T> Queryable<T> asQueryable(QueryProvider queryProvider, SchemaPlus schema, String tableName) Description copied from interface:QueryableTable
Converts this table into aQueryable
.- Specified by:
asQueryable
in interfaceQueryableTable
-
toRel
Description copied from interface:TranslatableTable
Converts this table into arelational expression
.- Specified by:
toRel
in interfaceTranslatableTable
-