Package org.apache.calcite.adapter.csv
Class CsvTable
- java.lang.Object
-
- org.apache.calcite.schema.impl.AbstractTable
-
- org.apache.calcite.adapter.csv.CsvTable
-
- Direct Known Subclasses:
CsvFilterableTable
,CsvScannableTable
,CsvTranslatableTable
public abstract class CsvTable extends AbstractTable
Base class for table that reads CSV files.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
CsvTable.Flavor
Various degrees of table "intelligence".
-
Field Summary
Fields Modifier and Type Field Description protected java.util.List<CsvFieldType>
fieldTypes
protected RelProtoDataType
protoRowType
protected Source
source
-
Constructor Summary
Constructors Constructor Description CsvTable(Source source, RelProtoDataType protoRowType)
Creates a CsvTable.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description RelDataType
getRowType(RelDataTypeFactory typeFactory)
Returns this table's row type.-
Methods inherited from class org.apache.calcite.schema.impl.AbstractTable
getJdbcTableType, getStatistic, isRolledUp, rolledUpColumnValidInsideAgg, unwrap
-
-
-
-
Field Detail
-
source
protected final Source source
-
protoRowType
protected final RelProtoDataType protoRowType
-
fieldTypes
protected java.util.List<CsvFieldType> fieldTypes
-
-
Constructor Detail
-
CsvTable
CsvTable(Source source, RelProtoDataType protoRowType)
Creates a CsvTable.
-
-
Method Detail
-
getRowType
public RelDataType getRowType(RelDataTypeFactory typeFactory)
Description copied from interface:Table
Returns this table's row type.This is a struct type whose fields describe the names and types of the columns in this table.
The implementer must use the type factory provided. This ensures that the type is converted into a canonical form; other equal types in the same query will use the same object.
- Parameters:
typeFactory
- Type factory with which to create the type- Returns:
- Row type
-
-