Package org.apache.calcite.schema
Interface ProjectableFilterableTable
-
- All Superinterfaces:
Table
public interface ProjectableFilterableTable extends Table
Table that can be scanned, optionally applying supplied filter expressions, and projecting a given list of columns, without creating an intermediate relational expression.If you wish to write a table that can apply projects but not filters, simply decline all filters.
- See Also:
ScannableTable
,FilterableTable
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Enumerable<java.lang.Object[]>
scan(DataContext root, java.util.List<RexNode> filters, int[] projects)
Returns an enumerable over the rows in this Table.-
Methods inherited from interface org.apache.calcite.schema.Table
getJdbcTableType, getRowType, getStatistic, isRolledUp, rolledUpColumnValidInsideAgg
-
-
-
-
Method Detail
-
scan
Enumerable<java.lang.Object[]> scan(DataContext root, java.util.List<RexNode> filters, int[] projects)
Returns an enumerable over the rows in this Table.Each row is represented as an array of its column values.
The list of filters is mutable. If the table can implement a particular filter, it should remove that filter from the list. If it cannot implement a filter, it should leave it in the list. Any filters remaining will be implemented by the consuming Calcite operator.
The projects are zero-based.
- Parameters:
root
- Execution contextfilters
- Mutable list of filters. The method should keep in the list any filters that it cannot apply.projects
- List of projects. Each is the 0-based ordinal of the column to project.- Returns:
- Enumerable over all rows that match the accepted filters, returning
for each row an array of column values, one value for each ordinal in
projects
.
-
-