Package org.spf4j.avro.calcite
Class AvroFilterableTable
- java.lang.Object
-
- org.spf4j.avro.calcite.AvroFilterableTable
-
- All Implemented Interfaces:
org.apache.calcite.schema.FilterableTable,org.apache.calcite.schema.Table
public final class AvroFilterableTable extends Object implements org.apache.calcite.schema.FilterableTable
An avro table when the data is provided by the provided Supplier of CloseableIterable of IndexedRecord- Author:
- Zoltan Farkas
-
-
Constructor Summary
Constructors Constructor Description AvroFilterableTable(org.apache.avro.Schema componentType, Supplier<org.spf4j.base.CloseableIterator<? extends org.apache.avro.generic.IndexedRecord>> dataSupplier)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.apache.avro.SchemagetComponentType()org.apache.calcite.schema.Schema.TableTypegetJdbcTableType()org.apache.calcite.rel.type.RelDataTypegetRowType(org.apache.calcite.rel.type.RelDataTypeFactory typeFactory)org.apache.calcite.schema.StatisticgetStatistic()Overwrite for better statistics.booleanisRolledUp(String column)booleanrolledUpColumnValidInsideAgg(String column, org.apache.calcite.sql.SqlCall call, org.apache.calcite.sql.SqlNode parent, org.apache.calcite.config.CalciteConnectionConfig config)org.apache.calcite.linq4j.Enumerable<Object[]>scan(org.apache.calcite.DataContext root, List<org.apache.calcite.rex.RexNode> filters)StringtoString()
-
-
-
Constructor Detail
-
AvroFilterableTable
public AvroFilterableTable(org.apache.avro.Schema componentType, Supplier<org.spf4j.base.CloseableIterator<? extends org.apache.avro.generic.IndexedRecord>> dataSupplier)
-
-
Method Detail
-
scan
public org.apache.calcite.linq4j.Enumerable<Object[]> scan(org.apache.calcite.DataContext root, List<org.apache.calcite.rex.RexNode> filters)
- Specified by:
scanin interfaceorg.apache.calcite.schema.FilterableTable
-
getRowType
public final org.apache.calcite.rel.type.RelDataType getRowType(org.apache.calcite.rel.type.RelDataTypeFactory typeFactory)
- Specified by:
getRowTypein interfaceorg.apache.calcite.schema.Table
-
getStatistic
@Nonnull public org.apache.calcite.schema.Statistic getStatistic()
Overwrite for better statistics.- Specified by:
getStatisticin interfaceorg.apache.calcite.schema.Table- Returns:
-
getJdbcTableType
public final org.apache.calcite.schema.Schema.TableType getJdbcTableType()
- Specified by:
getJdbcTableTypein interfaceorg.apache.calcite.schema.Table
-
isRolledUp
public final boolean isRolledUp(String column)
- Specified by:
isRolledUpin interfaceorg.apache.calcite.schema.Table
-
rolledUpColumnValidInsideAgg
public final boolean rolledUpColumnValidInsideAgg(String column, org.apache.calcite.sql.SqlCall call, org.apache.calcite.sql.SqlNode parent, org.apache.calcite.config.CalciteConnectionConfig config)
- Specified by:
rolledUpColumnValidInsideAggin interfaceorg.apache.calcite.schema.Table
-
getComponentType
public final org.apache.avro.Schema getComponentType()
-
-