protected class QueryJoinOptimizer.JoinVisitor extends AbstractQueryModelVisitor<RuntimeException>
Modifier | Constructor and Description |
---|---|
protected |
JoinVisitor() |
Modifier and Type | Method and Description |
---|---|
protected List<Var> |
getConstantVars(Iterable<Var> vars) |
protected List<Extension> |
getExtensions(List<TupleExpr> expressions) |
protected int |
getForeignVarFreq(List<Var> ownUnboundVars,
Map<Var,Integer> varFreqMap) |
protected <L extends List<TupleExpr>> |
getJoinArgs(TupleExpr tupleExpr,
L joinArgs) |
protected List<Var> |
getStatementPatternVars(TupleExpr tupleExpr) |
protected List<TupleExpr> |
getSubSelects(List<TupleExpr> expressions) |
protected double |
getTupleExprCardinality(TupleExpr tupleExpr,
Map<TupleExpr,Double> cardinalityMap,
Map<TupleExpr,List<Var>> varsMap,
Map<Var,Integer> varFreqMap,
Set<String> boundVars) |
protected List<Var> |
getUnboundVars(Iterable<Var> vars) |
protected <M extends Map<Var,Integer>> |
getVarFreqMap(List<Var> varList,
M varFreqMap) |
void |
meet(Join node) |
void |
meet(LeftJoin leftJoin) |
protected List<TupleExpr> |
reorderSubselects(List<TupleExpr> subselects)
Determines an optimal ordering of subselect join arguments, based on variable bindings.
|
protected TupleExpr |
selectNextTupleExpr(List<TupleExpr> expressions,
Map<TupleExpr,Double> cardinalityMap,
Map<TupleExpr,List<Var>> varsMap,
Map<Var,Integer> varFreqMap,
Set<String> boundVars)
Selects from a list of tuple expressions the next tuple expression that should be evaluated.
|
meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meetBinaryTupleOperator, meetBinaryValueOperator, meetCompareSubQueryValueOperator, meetNAryValueOperator, meetNode, meetOther, meetSubQueryValueOperator, meetUnaryTupleOperator, meetUnaryValueOperator, meetUpdateExpr
public void meet(LeftJoin leftJoin)
meet
in interface QueryModelVisitor<RuntimeException>
meet
in class AbstractQueryModelVisitor<RuntimeException>
public void meet(Join node)
meet
in interface QueryModelVisitor<RuntimeException>
meet
in class AbstractQueryModelVisitor<RuntimeException>
protected <M extends Map<Var,Integer>> M getVarFreqMap(List<Var> varList, M varFreqMap)
protected List<TupleExpr> reorderSubselects(List<TupleExpr> subselects)
Example: reordering
[f] [a b c] [e f] [a d] [b e]should result in:
[a b c] [a d] [b e] [e f] [f]
subselects
- the original ordering of expressionsprotected TupleExpr selectNextTupleExpr(List<TupleExpr> expressions, Map<TupleExpr,Double> cardinalityMap, Map<TupleExpr,List<Var>> varsMap, Map<Var,Integer> varFreqMap, Set<String> boundVars)
protected double getTupleExprCardinality(TupleExpr tupleExpr, Map<TupleExpr,Double> cardinalityMap, Map<TupleExpr,List<Var>> varsMap, Map<Var,Integer> varFreqMap, Set<String> boundVars)
Copyright © 2015-2020 Eclipse Foundation. All Rights Reserved.