Class CsvTable

java.lang.Object
org.apache.calcite.schema.impl.AbstractTable
org.apache.calcite.adapter.file.CsvTable
All Implemented Interfaces:
Table, Wrapper
Direct Known Subclasses:
CsvTranslatableTable

public abstract class CsvTable extends AbstractTable
Base class for table that reads CSV files.

Copied from CsvFilterableTable in demo CSV adapter, with more advanced features.

  • Field Details

  • Method Details

    • 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
    • getFieldTypes

      public List<RelDataType> getFieldTypes(RelDataTypeFactory typeFactory)
      Returns the field types of this CSV table.
    • isStream

      protected boolean isStream()
      Returns whether the table represents a stream.