Package org.apache.calcite.rel.metadata
Defines metadata interfaces and utilities for relational
expressions.
-
Interface Summary Interface Description BuiltInMetadata.All The built-in forms of metadata.BuiltInMetadata.AllPredicates Metadata about the predicates that hold in the rows emitted from a relational expression.BuiltInMetadata.AllPredicates.Handler Handler API.BuiltInMetadata.Collation Metadata about which columns are sorted.BuiltInMetadata.Collation.Handler Handler API.BuiltInMetadata.ColumnOrigin Metadata about the origins of columns.BuiltInMetadata.ColumnOrigin.Handler Handler API.BuiltInMetadata.ColumnUniqueness Metadata about whether a set of columns uniquely identifies a row.BuiltInMetadata.ColumnUniqueness.Handler Handler API.BuiltInMetadata.CumulativeCost Metadata about the cost of evaluating a relational expression, including all of its inputs.BuiltInMetadata.CumulativeCost.Handler Handler API.BuiltInMetadata.DistinctRowCount Metadata about the number of distinct rows returned by a set of columns in a relational expression.BuiltInMetadata.DistinctRowCount.Handler Handler API.BuiltInMetadata.Distribution Metadata about how a relational expression is distributed.BuiltInMetadata.Distribution.Handler Handler API.BuiltInMetadata.ExplainVisibility Metadata about whether a relational expression should appear in a plan.BuiltInMetadata.ExplainVisibility.Handler Handler API.BuiltInMetadata.ExpressionLineage Metadata about the origins of expressions.BuiltInMetadata.ExpressionLineage.Handler Handler API.BuiltInMetadata.MaxRowCount Metadata about the maximum number of rows returned by a relational expression.BuiltInMetadata.MaxRowCount.Handler Handler API.BuiltInMetadata.Memory Metadata about the memory use of an operator.BuiltInMetadata.Memory.Handler Handler API.BuiltInMetadata.MinRowCount Metadata about the minimum number of rows returned by a relational expression.BuiltInMetadata.MinRowCount.Handler Handler API.BuiltInMetadata.NodeTypes Metadata about the node types in a relational expression.BuiltInMetadata.NodeTypes.Handler Handler API.BuiltInMetadata.NonCumulativeCost Metadata about the cost of evaluating a relational expression, not including its inputs.BuiltInMetadata.NonCumulativeCost.Handler Handler API.BuiltInMetadata.Parallelism Metadata about the degree of parallelism of a relational expression, and how its operators are assigned to processes with independent resource pools.BuiltInMetadata.Parallelism.Handler Handler API.BuiltInMetadata.PercentageOriginalRows Metadata about the proportion of original rows that remain in a relational expression.BuiltInMetadata.PercentageOriginalRows.Handler Handler API.BuiltInMetadata.PopulationSize Metadata about the number of distinct values in the original source of a column or set of columns.BuiltInMetadata.PopulationSize.Handler Handler API.BuiltInMetadata.Predicates Metadata about the predicates that hold in the rows emitted from a relational expression.BuiltInMetadata.Predicates.Handler Handler API.BuiltInMetadata.RowCount Metadata about the number of rows returned by a relational expression.BuiltInMetadata.RowCount.Handler Handler API.BuiltInMetadata.Selectivity Metadata about the selectivity of a predicate.BuiltInMetadata.Selectivity.Handler Handler API.BuiltInMetadata.Size Metadata about the size of rows and columns.BuiltInMetadata.Size.Handler Handler API.BuiltInMetadata.TableReferences Metadata to obtain references to tables used by a given expression.BuiltInMetadata.TableReferences.Handler Handler API.BuiltInMetadata.UniqueKeys Metadata about which combinations of columns are unique identifiers.BuiltInMetadata.UniqueKeys.Handler Handler API.Metadata Metadata about a relational expression.MetadataFactory Source of metadata about relational expressions.MetadataHandler<M extends Metadata> Marker interface for a handler of metadata.RelMetadataProvider RelMetadataProvider defines an interface for obtaining metadata about relational expressions.UnboundMetadata<M extends Metadata> Metadata that needs to be bound to aRelNode
andRelMetadataQuery
before it can be used. -
Class Summary Class Description BuiltInMetadata Contains the interfaces for several common forms of metadata.CachingRelMetadataProvider Implementation of theRelMetadataProvider
interface that caches results from an underlying provider.CachingRelMetadataProvider.CacheEntry An entry in the cache.ChainedRelMetadataProvider Implementation of theRelMetadataProvider
interface via theGlossary.CHAIN_OF_RESPONSIBILITY_PATTERN
.ChainedRelMetadataProvider.ChainedInvocationHandler Invocation handler that calls a list ofMetadata
objects, returning the first non-null value.DefaultRelMetadataProvider DefaultRelMetadataProvider supplies a default implementation of theRelMetadataProvider
interface.JaninoRelMetadataProvider Implementation of theRelMetadataProvider
interface that generates a class that dispatches to the underlying providers.JaninoRelMetadataProvider.Key Key for the cache.MetadataDef<M extends Metadata> Definition of metadata.MetadataFactoryImpl Implementation ofMetadataFactory
that gets providers from aRelMetadataProvider
and stores them in a cache.ReflectiveRelMetadataProvider Implementation of theRelMetadataProvider
interface that dispatches metadata methods to methods on a given object via reflection.ReflectiveRelMetadataProvider.Space Workspace for computing which methods can act as handlers for given metadata methods.ReflectiveRelMetadataProvider.Space2 Extended work space.RelColumnMapping Mapping from an input column of aRelNode
to one of its output columns.RelColumnOrigin RelColumnOrigin is a data structure describing one of the origins of an output column produced by a relational expression.RelMdAllPredicates Utility to extract Predicates that are present in the (sub)plan starting at this node.RelMdCollation RelMdCollation supplies a default implementation ofRelMetadataQuery.collations(org.apache.calcite.rel.RelNode)
for the standard logical algebra.RelMdColumnOrigins RelMdColumnOrigins supplies a default implementation ofRelMetadataQuery.getColumnOrigins(org.apache.calcite.rel.RelNode, int)
for the standard logical algebra.RelMdColumnUniqueness RelMdColumnUniqueness supplies a default implementation ofRelMetadataQuery.areColumnsUnique(org.apache.calcite.rel.RelNode, org.apache.calcite.util.ImmutableBitSet)
for the standard logical algebra.RelMdDistinctRowCount RelMdDistinctRowCount supplies a default implementation ofRelMetadataQuery.getDistinctRowCount(org.apache.calcite.rel.RelNode, org.apache.calcite.util.ImmutableBitSet, org.apache.calcite.rex.RexNode)
for the standard logical algebra.RelMdDistribution RelMdCollation supplies a default implementation ofRelMetadataQuery.distribution(org.apache.calcite.rel.RelNode)
for the standard logical algebra.RelMdExplainVisibility RelMdExplainVisibility supplies a default implementation ofRelMetadataQuery.isVisibleInExplain(org.apache.calcite.rel.RelNode, org.apache.calcite.sql.SqlExplainLevel)
for the standard logical algebra.RelMdExpressionLineage Default implementation ofRelMetadataQuery.getExpressionLineage(org.apache.calcite.rel.RelNode, org.apache.calcite.rex.RexNode)
for the standard logical algebra.RelMdExpressionLineage.RexReplacer Replaces expressions with their equivalences.RelMdMaxRowCount RelMdMaxRowCount supplies a default implementation ofRelMetadataQuery.getMaxRowCount(org.apache.calcite.rel.RelNode)
for the standard logical algebra.RelMdMemory Default implementations of theBuiltInMetadata.Memory
metadata provider for the standard logical algebra.RelMdMinRowCount RelMdMinRowCount supplies a default implementation ofRelMetadataQuery.getMinRowCount(org.apache.calcite.rel.RelNode)
for the standard logical algebra.RelMdNodeTypes RelMdNodeTypeCount supplies a default implementation ofRelMetadataQuery.getNodeTypes(org.apache.calcite.rel.RelNode)
for the standard logical algebra.RelMdParallelism Default implementations of theBuiltInMetadata.Parallelism
metadata provider for the standard logical algebra.RelMdPercentageOriginalRows RelMdPercentageOriginalRows supplies a default implementation ofRelMetadataQuery.getPercentageOriginalRows(org.apache.calcite.rel.RelNode)
for the standard logical algebra.RelMdPopulationSize RelMdPopulationSize supplies a default implementation ofRelMetadataQuery.getPopulationSize(org.apache.calcite.rel.RelNode, org.apache.calcite.util.ImmutableBitSet)
for the standard logical algebra.RelMdPredicates Utility to infer Predicates that are applicable above a RelNode.RelMdPredicates.JoinConditionBasedPredicateInference Utility to infer predicates from one side of the join that apply on the other side.RelMdRowCount RelMdRowCount supplies a default implementation ofRelMetadataQuery.getRowCount(org.apache.calcite.rel.RelNode)
for the standard logical algebra.RelMdSelectivity RelMdSelectivity supplies a default implementation ofRelMetadataQuery.getSelectivity(org.apache.calcite.rel.RelNode, org.apache.calcite.rex.RexNode)
for the standard logical algebra.RelMdSize Default implementations of theBuiltInMetadata.Size
metadata provider for the standard logical algebra.RelMdTableReferences Default implementation ofRelMetadataQuery.getTableReferences(org.apache.calcite.rel.RelNode)
for the standard logical algebra.RelMdUniqueKeys RelMdUniqueKeys supplies a default implementation ofRelMetadataQuery.getUniqueKeys(org.apache.calcite.rel.RelNode)
for the standard logical algebra.RelMdUtil RelMdUtil provides utility methods used by the metadata provider methods.RelMdUtil.CardOfProjExpr Visitor that walks over a scalar expression and computes the cardinality of its result.RelMetadataQuery RelMetadataQuery provides a strongly-typed facade on top ofRelMetadataProvider
for the set of relational expression metadata queries defined as standard within Calcite. -
Enum Summary Enum Description NullSentinel Placeholder for null values. -
Exception Summary Exception Description CyclicMetadataException Exception that indicates that a cycle has been detected while computing metadata.JaninoRelMetadataProvider.NoHandler Exception that indicates there there should be a handler for this class but there is not.