protected static Op join(Op current, Op newOp) { if ( simplifyTooEarlyInAlgebraGeneration && applySimplification ) return OpJoin.createReduce(current, newOp) ; return OpJoin.create(current, newOp) ; }
private static Op join(Op op1, Op op2) { return OpJoin.create(op1, op2) ; }
/** * Parses the joins and recursively calls the left and right parts */ @Override public void visit(final OpJoin opJoin) { if (LOG.isDebugEnabled()) { LOG.debug("Starting visiting OpJoin"); } final OpRewriter rewriter = new OpRewriter(securityEvaluator, graphIRI); addOp(OpJoin.create(rewriteOp2(opJoin, rewriter), rewriter.getResult())); }
@Override public Op make(ItemList list) { BuilderLib.checkLength(3, list, "Join") ; Op left = build(list, 1) ; Op right = build(list, 2) ; Op op = OpJoin.create(left, right) ; return op ; } } ;
public Op getApplicableViews(OpJoin op, RestrictionManagerImpl restrictions) { return OpJoin.create(_getApplicableViews(op.getLeft(), restrictions), _getApplicableViews(op.getRight(), restrictions)); }
public static Op _replace(OpJoin op) { return OpJoin.create(replace(op.getLeft()), replace(op.getRight())); }
public static Op _optimize(OpJoin op, Set<Set<Expr>> cnf) { Set<Set<Expr>> leftCnf = filterByVars(cnf, op.getLeft()); Set<Set<Expr>> rightCnf = filterByVars(cnf, op.getLeft()); Set<Set<Expr>> union = Sets.union(leftCnf, rightCnf); Set<Set<Expr>> remaining = Sets.difference(cnf, union); Op result = OpJoin.create(optimize(op.getLeft(), leftCnf), optimize(op.getRight(), rightCnf)); if(!remaining.isEmpty()) { result = OpFilter.filter(cnfToExprList(remaining), result); } return result; }
OpTable opTable = OpTable.create(table); executionOp = executionOp instanceof OpNull ? opTable : OpJoin.create(opTable, executionOp);
OpTable opTable = OpTable.create(table); executionOp = executionOp instanceof OpNull ? opTable : OpJoin.create(opTable, executionOp);
@Override public void visit(OpJoin opJoin) { opJoin.getRight().visit(this); opJoin.getLeft().visit(this); push(OpJoin.create(pop(), pop())); }
public Op _optimizeBreaking(OpJoin op, RestrictionManagerImpl cnf) { RestrictionManagerImpl leftCnf = filterByVars(cnf, op.getLeft()); RestrictionManagerImpl rightCnf = filterByVars(cnf, op.getRight()); Set<Clause> union = Sets.union(leftCnf.getCnf(), rightCnf.getCnf()); Set<Clause> remaining = Sets.difference(cnf.getCnf(), union); Op result = OpJoin.create(optimize(op.getLeft(), leftCnf), optimize(op.getRight(), rightCnf)); if(!remaining.isEmpty()) { //result = OpFilter.filter(cnfToExprList(remaining), result); result = OpFilterIndexed.filter(new RestrictionManagerImpl(new NestedNormalForm(remaining)), result); } return result; }
a = OpJoin.create(a, b);
@Override public void visit(OpJoin opJoin) { opJoin.getRight().visit(this); opJoin.getLeft().visit(this); push(OpJoin.create(pop(), pop())); }
opRightNew = transformOpAlways(pushRight, opRightNew) ; Op op = OpJoin.create(opLeftNew, opRightNew) ; return result(op, unpushed) ;
item = OpJoin.create(member, newRight); item = new OpFilterIndexed(item, rsplit.getNonPushable());
table.addBinding(binding) ; OpTable opTable = OpTable.create(table) ; op = OpJoin.create(op, opTable) ;