public interface RelOptTable extends Wrapper
RelOptSchema. It has methods to
describe and implement itself.| Modifier and Type | Interface and Description |
|---|---|
static interface |
RelOptTable.ToRelContext
Contains the context needed to convert a a table into a relational
expression.
|
static interface |
RelOptTable.ViewExpander
Can expand a view into relational expressions.
|
| Modifier and Type | Method and Description |
|---|---|
RelOptTable |
extend(List<RelDataTypeField> extendedFields)
Returns a table with the given extra fields.
|
@Nullable List<RelCollation> |
getCollationList()
Returns a description of the physical ordering (or orderings) of the rows
returned from this table.
|
List<ColumnStrategy> |
getColumnStrategies()
Returns a list describing how each column is populated.
|
@Nullable RelDistribution |
getDistribution()
Returns a description of the physical distribution of the rows
in this table.
|
@Nullable org.apache.calcite.linq4j.tree.Expression |
getExpression(Class clazz)
Generates code for this table.
|
@Nullable List<ImmutableBitSet> |
getKeys()
Returns a list of unique keys, empty list if no key exist,
the result should be consistent with
isKey. |
List<String> |
getQualifiedName()
Obtains an identifier for this table.
|
@Nullable List<RelReferentialConstraint> |
getReferentialConstraints()
Returns the referential constraints existing for this table.
|
@Nullable RelOptSchema |
getRelOptSchema()
Returns the
RelOptSchema this table belongs to. |
double |
getRowCount()
Returns an estimate of the number of rows in the table.
|
RelDataType |
getRowType()
Describes the type of rows returned by this table.
|
boolean |
isKey(ImmutableBitSet columns)
Returns whether the given columns are a key or a superset of a unique key
of this table.
|
RelNode |
toRel(RelOptTable.ToRelContext context)
Converts this table into a
relational expression. |
maybeUnwrap, unwrap, unwrapOrThrowList<String> getQualifiedName()
double getRowCount()
RelDataType getRowType()
@Nullable RelOptSchema getRelOptSchema()
RelOptSchema this table belongs to.RelNode toRel(RelOptTable.ToRelContext context)
relational expression.
The planner calls this
method to convert a table into an initial relational expression,
generally something abstract, such as a
LogicalTableScan,
then optimizes this expression by
applying rules to transform it
into more efficient access methods for this table.
@Nullable List<RelCollation> getCollationList()
RelMetadataQuery.collations(RelNode)@Nullable RelDistribution getDistribution()
RelMetadataQuery.distribution(RelNode)boolean isKey(ImmutableBitSet columns)
columns - Ordinals of key columns@Nullable List<ImmutableBitSet> getKeys()
isKey.@Nullable List<RelReferentialConstraint> getReferentialConstraints()
RelReferentialConstraint nodes.@Nullable org.apache.calcite.linq4j.tree.Expression getExpression(Class clazz)
clazz - The desired collection class; for example Queryable.RelOptTable extend(List<RelDataTypeField> extendedFields)
The extended table includes the fields of this base table plus the extended fields that do not have the same name as a field in the base table.
List<ColumnStrategy> getColumnStrategies()
Copyright © 2012-2022 Apache Software Foundation. All Rights Reserved.