public class MaterializedViewSubstitutionVisitor extends SubstitutionVisitor
SubstitutionVisitor
.Modifier and Type | Class and Description |
---|---|
private static class |
MaterializedViewSubstitutionVisitor.FilterToFilterUnifyRule1
Implementation of
SubstitutionVisitor.UnifyRule that matches a
MutableFilter to a
MutableFilter where the condition of the target
relation is weaker. |
private static class |
MaterializedViewSubstitutionVisitor.FilterToProjectUnifyRule1
Implementation of
SubstitutionVisitor.UnifyRule that matches a
MutableFilter to a
MutableProject on top of a
MutableFilter where the condition of the target
relation is weaker. |
private static class |
MaterializedViewSubstitutionVisitor.ProjectToProjectUnifyRule1
Implementation of
SubstitutionVisitor.UnifyRule that matches a
MutableProject to a
MutableProject where the condition of the target
relation is weaker. |
SubstitutionVisitor.AbstractUnifyRule, SubstitutionVisitor.FilterOnProjectRule, SubstitutionVisitor.MatchFailed, SubstitutionVisitor.Operand, SubstitutionVisitor.Replacement, SubstitutionVisitor.UnifyResult, SubstitutionVisitor.UnifyRule, SubstitutionVisitor.UnifyRuleCall
Modifier and Type | Field and Description |
---|---|
private static com.google.common.collect.ImmutableList<SubstitutionVisitor.UnifyRule> |
EXTENDED_RULES |
DEFAULT_RULES, equivalents, queryLeaves, relBuilder, replacementMap, slots, targetLeaves
Constructor and Description |
---|
MaterializedViewSubstitutionVisitor(RelNode target_,
RelNode query_) |
MaterializedViewSubstitutionVisitor(RelNode target_,
RelNode query_,
RelBuilderFactory relBuilderFactory) |
Modifier and Type | Method and Description |
---|---|
java.util.List<RelNode> |
go(RelNode replacement_)
Returns a list of all possible rels that result from substituting the
matched RelNode with the replacement RelNode within the query.
|
private static java.util.List<RexNode> |
transformRex(java.util.List<RexNode> nodes,
java.util.List<RelDataTypeField> oldFields,
java.util.List<RelDataTypeField> newFields) |
private static RexNode |
transformRex(RexNode node,
java.util.List<RelDataTypeField> oldFields,
java.util.List<RelDataTypeField> newFields) |
equalType, getRexShuttle, getRollup, go0, isWeaker, mayBeSatisfiable, permute, register, replace, splitFilter, unifyAggregates
private static final com.google.common.collect.ImmutableList<SubstitutionVisitor.UnifyRule> EXTENDED_RULES
public MaterializedViewSubstitutionVisitor(RelNode target_, RelNode query_)
public MaterializedViewSubstitutionVisitor(RelNode target_, RelNode query_, RelBuilderFactory relBuilderFactory)
public java.util.List<RelNode> go(RelNode replacement_)
SubstitutionVisitor
For example, the substitution result of A join B, while A and B are both a qualified match for replacement R, is R join B, R join R, A join R.
go
in class SubstitutionVisitor
private static RexNode transformRex(RexNode node, java.util.List<RelDataTypeField> oldFields, java.util.List<RelDataTypeField> newFields)
private static java.util.List<RexNode> transformRex(java.util.List<RexNode> nodes, java.util.List<RelDataTypeField> oldFields, java.util.List<RelDataTypeField> newFields)
Copyright © 2012–2019 The Apache Software Foundation. All rights reserved.