public class InnerJoinNodeImpl extends JoinLikeNodeImpl implements InnerJoinNode
substitutionFactory, substitutionTools, termFactory, typeFactory, unificationTools| Modifier | Constructor and Description |
|---|---|
protected |
InnerJoinNodeImpl(Optional<ImmutableExpression> optionalFilterCondition,
TermNullabilityEvaluator nullabilityEvaluator,
TermFactory termFactory,
TypeFactory typeFactory,
IntermediateQueryFactory iqFactory,
SubstitutionFactory substitutionFactory,
ConstructionNodeTools constructionNodeTools,
ImmutableUnificationTools unificationTools,
ImmutableSubstitutionTools substitutionTools,
JoinOrFilterVariableNullabilityTools variableNullabilityTools,
ConditionSimplifier conditionSimplifier,
InnerJoinNormalizer normalizer) |
| Modifier and Type | Method and Description |
|---|---|
InnerJoinNode |
acceptNodeTransformer(HomogeneousQueryNodeTransformer transformer)
"Accept" method for the "Visitor" pattern.
|
IQTree |
acceptTransformer(IQTree tree,
IQTreeVisitingTransformer transformer,
com.google.common.collect.ImmutableList<IQTree> children) |
<T> T |
acceptVisitor(IQVisitor<T> visitor,
com.google.common.collect.ImmutableList<IQTree> children) |
void |
acceptVisitor(QueryNodeVisitor visitor)
"Accept" method for the "Visitor" pattern.
|
IQTree |
applyDescendingSubstitution(ImmutableSubstitution<? extends VariableOrGroundTerm> descendingSubstitution,
Optional<ImmutableExpression> constraint,
com.google.common.collect.ImmutableList<IQTree> children) |
IQTree |
applyDescendingSubstitutionWithoutOptimizing(ImmutableSubstitution<? extends VariableOrGroundTerm> descendingSubstitution,
com.google.common.collect.ImmutableList<IQTree> children) |
IQTree |
applyFreshRenaming(InjectiveVar2VarSubstitution renamingSubstitution,
com.google.common.collect.ImmutableList<IQTree> children,
IQTreeCache treeCache) |
InnerJoinNode |
changeOptionalFilterCondition(Optional<ImmutableExpression> newOptionalFilterCondition)
Constructs a new JoinLikeNode with the following optional filter condition
(recall that a QueryNode is immutable).
|
InnerJoinNode |
clone()
See https://stackoverflow.com/questions/6837362/
|
com.google.common.collect.ImmutableSet<Variable> |
computeNotInternallyRequiredVariables(com.google.common.collect.ImmutableList<IQTree> children) |
com.google.common.collect.ImmutableSet<ImmutableSubstitution<NonVariableTerm>> |
getPossibleVariableDefinitions(com.google.common.collect.ImmutableList<IQTree> children) |
VariableNullability |
getVariableNullability(com.google.common.collect.ImmutableList<IQTree> children) |
com.google.common.collect.ImmutableSet<com.google.common.collect.ImmutableSet<Variable>> |
inferUniqueConstraints(com.google.common.collect.ImmutableList<IQTree> children)
For unique constraints to emerge from an inner join, children must provide unique constraints
and being naturally joined over some of such constraints.
|
boolean |
isConstructed(Variable variable,
com.google.common.collect.ImmutableList<IQTree> children) |
boolean |
isDistinct(IQTree tree,
com.google.common.collect.ImmutableList<IQTree> children) |
boolean |
isEquivalentTo(QueryNode queryNode)
Is syntactically equivalent
|
boolean |
isSyntacticallyEquivalentTo(QueryNode node)
TODO: explain
|
boolean |
isVariableNullable(IntermediateQuery query,
Variable variable)
Returns true if it cannot guarantee the projected variable to be non-null
Throws an IllegalArgumentException if the variable is not projected by the node
|
IQTree |
liftIncompatibleDefinitions(Variable variable,
com.google.common.collect.ImmutableList<IQTree> children,
VariableGenerator variableGenerator) |
IQTree |
normalizeForOptimization(com.google.common.collect.ImmutableList<IQTree> children,
VariableGenerator variableGenerator,
IQProperties currentIQProperties)
TODO: refactor
|
IQTree |
propagateDownConstraint(ImmutableExpression constraint,
com.google.common.collect.ImmutableList<IQTree> children) |
IQTree |
removeDistincts(com.google.common.collect.ImmutableList<IQTree> children,
IQProperties properties) |
String |
toString() |
void |
validateNode(com.google.common.collect.ImmutableList<IQTree> children)
Only validates the node, not its children
|
checkNonProjectedVariables, getRequiredVariablescheckExpression, getLocallyDefinedVariables, getLocallyRequiredVariables, getLocalVariables, getNullabilityEvaluator, getOptionalFilterCondition, getOptionalFilterString, isFilteringNullValueequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetOptionalFilterConditiongetLocallyDefinedVariables, getLocallyRequiredVariables, getLocalVariables, getRequiredVariablesprotected InnerJoinNodeImpl(Optional<ImmutableExpression> optionalFilterCondition, TermNullabilityEvaluator nullabilityEvaluator, TermFactory termFactory, TypeFactory typeFactory, IntermediateQueryFactory iqFactory, SubstitutionFactory substitutionFactory, ConstructionNodeTools constructionNodeTools, ImmutableUnificationTools unificationTools, ImmutableSubstitutionTools substitutionTools, JoinOrFilterVariableNullabilityTools variableNullabilityTools, ConditionSimplifier conditionSimplifier, InnerJoinNormalizer normalizer)
public void acceptVisitor(QueryNodeVisitor visitor)
QueryNodeacceptVisitor in interface QueryNodepublic InnerJoinNode clone()
QueryNodeImplclone in interface InnerJoinLikeNodeclone in interface InnerJoinNodeclone in interface QueryNodeclone in class QueryNodeImplpublic InnerJoinNode acceptNodeTransformer(HomogeneousQueryNodeTransformer transformer) throws QueryNodeTransformationException
QueryNodeacceptNodeTransformer in interface InnerJoinLikeNodeacceptNodeTransformer in interface InnerJoinNodeacceptNodeTransformer in interface NaryOperatorNodeacceptNodeTransformer in interface QueryNodeQueryNodeTransformationExceptionpublic com.google.common.collect.ImmutableSet<ImmutableSubstitution<NonVariableTerm>> getPossibleVariableDefinitions(com.google.common.collect.ImmutableList<IQTree> children)
getPossibleVariableDefinitions in interface NaryOperatorNodepublic InnerJoinNode changeOptionalFilterCondition(Optional<ImmutableExpression> newOptionalFilterCondition)
JoinLikeNodechangeOptionalFilterCondition in interface CommutativeJoinNodechangeOptionalFilterCondition in interface InnerJoinLikeNodechangeOptionalFilterCondition in interface InnerJoinNodechangeOptionalFilterCondition in interface JoinLikeNodepublic boolean isVariableNullable(IntermediateQuery query, Variable variable)
QueryNodeisVariableNullable in interface QueryNodepublic boolean isSyntacticallyEquivalentTo(QueryNode node)
QueryNodeisSyntacticallyEquivalentTo in interface QueryNodepublic boolean isEquivalentTo(QueryNode queryNode)
QueryNodeisEquivalentTo in interface QueryNodepublic IQTree normalizeForOptimization(com.google.common.collect.ImmutableList<IQTree> children, VariableGenerator variableGenerator, IQProperties currentIQProperties)
normalizeForOptimization in interface NaryOperatorNodepublic IQTree applyDescendingSubstitution(ImmutableSubstitution<? extends VariableOrGroundTerm> descendingSubstitution, Optional<ImmutableExpression> constraint, com.google.common.collect.ImmutableList<IQTree> children)
applyDescendingSubstitution in interface NaryOperatorNodepublic IQTree applyDescendingSubstitutionWithoutOptimizing(ImmutableSubstitution<? extends VariableOrGroundTerm> descendingSubstitution, com.google.common.collect.ImmutableList<IQTree> children)
applyDescendingSubstitutionWithoutOptimizing in interface NaryOperatorNodepublic IQTree applyFreshRenaming(InjectiveVar2VarSubstitution renamingSubstitution, com.google.common.collect.ImmutableList<IQTree> children, IQTreeCache treeCache)
applyFreshRenaming in interface NaryOperatorNodepublic VariableNullability getVariableNullability(com.google.common.collect.ImmutableList<IQTree> children)
getVariableNullability in interface NaryOperatorNodepublic boolean isConstructed(Variable variable, com.google.common.collect.ImmutableList<IQTree> children)
isConstructed in interface NaryOperatorNodepublic boolean isDistinct(IQTree tree, com.google.common.collect.ImmutableList<IQTree> children)
isDistinct in interface NaryOperatorNodeisDistinct in class JoinOrFilterNodeImplpublic IQTree liftIncompatibleDefinitions(Variable variable, com.google.common.collect.ImmutableList<IQTree> children, VariableGenerator variableGenerator)
liftIncompatibleDefinitions in interface NaryOperatorNodepublic IQTree propagateDownConstraint(ImmutableExpression constraint, com.google.common.collect.ImmutableList<IQTree> children)
propagateDownConstraint in interface NaryOperatorNodepublic IQTree acceptTransformer(IQTree tree, IQTreeVisitingTransformer transformer, com.google.common.collect.ImmutableList<IQTree> children)
acceptTransformer in interface NaryOperatorNodepublic <T> T acceptVisitor(IQVisitor<T> visitor, com.google.common.collect.ImmutableList<IQTree> children)
acceptVisitor in interface NaryOperatorNodepublic void validateNode(com.google.common.collect.ImmutableList<IQTree> children) throws InvalidIntermediateQueryException
NaryOperatorNodevalidateNode in interface NaryOperatorNodeInvalidIntermediateQueryExceptionpublic IQTree removeDistincts(com.google.common.collect.ImmutableList<IQTree> children, IQProperties properties)
removeDistincts in interface NaryOperatorNodepublic com.google.common.collect.ImmutableSet<com.google.common.collect.ImmutableSet<Variable>> inferUniqueConstraints(com.google.common.collect.ImmutableList<IQTree> children)
inferUniqueConstraints in interface NaryOperatorNodepublic com.google.common.collect.ImmutableSet<Variable> computeNotInternallyRequiredVariables(com.google.common.collect.ImmutableList<IQTree> children)
computeNotInternallyRequiredVariables in interface NaryOperatorNodecomputeNotInternallyRequiredVariables in class JoinOrFilterNodeImplCopyright © 2009–2020 Free University of Bozen-Bolzano. All rights reserved.