Examples of AndPredicate


Examples of plan_runner.predicates.AndPredicate

    final Multiplication mult = new Multiplication(value10, colLineItemsInequality);
    final ColumnReference colOrdersInequality = new ColumnReference(_doubleConv, 1);
    final ComparisonPredicate pred2 = new ComparisonPredicate(ComparisonPredicate.LESS_OP,
        mult, colOrdersInequality);

    final AndPredicate overallPred = new AndPredicate(pred1, pred2);

    Component lastJoiner = ThetaJoinComponentFactory
        .createThetaJoinOperator(Theta_JoinType, relationLineitem, relationOrders,
            _queryPlan).setJoinPredicate(overallPred)
        .addOperator(new ProjectOperator(new int[] { 1, 2, 4 })).addOperator(agg);
View Full Code Here

Examples of plan_runner.predicates.AndPredicate

    ComparisonPredicate P_L_PS1_comp = new ComparisonPredicate(ComparisonPredicate.EQUAL_OP,
        colP_L1, colPS1);

    ComparisonPredicate P_L_PS2_comp = new ComparisonPredicate(ComparisonPredicate.EQUAL_OP,
        colP_L2, colPS2);
    AndPredicate P_L_PS = new AndPredicate(P_L_PS1_comp, P_L_PS2_comp);

    Component P_L_PSjoin = ThetaJoinComponentFactory
        .createThetaJoinOperator(Theta_JoinType, P_Ljoin, relationPartsupp, _queryPlan)
        .setHashIndexes(Arrays.asList(0))
        .addOperator(new ProjectOperator(new int[] { 1, 2, 3, 4, 5, 8 }))
View Full Code Here

Examples of plan_runner.predicates.AndPredicate

    final ValueSpecification val10 = new ValueSpecification(_doubleConv, 10.0);
    final Multiplication mult = new Multiplication(val10, colRefLineItemExtPrice);
    final ComparisonPredicate predL_O2 = new ComparisonPredicate(ComparisonPredicate.LESS_OP,
        mult, colRefOrdersTotalPrice);

    final AndPredicate predL_O = new AndPredicate(predL_O1, predL_O2);

    Component LINEITEMS_ORDERSjoin = ThetaJoinComponentFactory
        .createThetaJoinOperator(Theta_JoinType, relationLineitem, relationOrders,
            _queryPlan).setJoinPredicate(predL_O)
        .addOperator(new ProjectOperator(new int[] { 1, 2, 3, 4 }));

    // -------------------------------------------------------------------------------------

    final SelectOperator selectionPartSupp = new SelectOperator(new ComparisonPredicate(
        ComparisonPredicate.GREATER_OP, new ColumnReference(_intConv, 2),
        new ValueSpecification(_intConv, 9990)));

    final ColumnReference colRefSupplier = new ColumnReference(_intConv, 0);
    final ColumnReference colRefPartSupp = new ColumnReference(_intConv, 1);
    final ComparisonPredicate predS_P = new ComparisonPredicate(ComparisonPredicate.EQUAL_OP,
        colRefSupplier, colRefPartSupp);

    Component SUPPLIER_PARTSUPPjoin = ThetaJoinComponentFactory
        .createThetaJoinOperator(Theta_JoinType, relationSupplier, relationPartsupp,
            _queryPlan).setJoinPredicate(predS_P)
        .addOperator(new ProjectOperator(new int[] { 0, 1, 3 }))
        .addOperator(selectionPartSupp);

    // -------------------------------------------------------------------------------------

    // set up aggregation function on the StormComponent(Bolt) where join is
    // performed

    // 1 - discount
    final ValueExpression<Double> substract = new Subtraction(new ValueSpecification(
        _doubleConv, 1.0), new ColumnReference(_doubleConv, 3));
    // extendedPrice*(1-discount)
    final ValueExpression<Double> product = new Multiplication(new ColumnReference(_doubleConv,
        2), substract);
    final AggregateOperator agg = new AggregateSumOperator(product, conf);

    final ColumnReference colRefL_OPartKey = new ColumnReference(_intConv, 0);
    final ColumnReference colRefS_PPartKey = new ColumnReference(_intConv, 1);
    final ColumnReference colRefL_OSupKey = new ColumnReference(_intConv, 1);
    final ColumnReference colRefS_PSupKey = new ColumnReference(_intConv, 0);
    final ComparisonPredicate predL_P1 = new ComparisonPredicate(ComparisonPredicate.EQUAL_OP,
        colRefL_OPartKey, colRefS_PPartKey);
    final ComparisonPredicate predL_P2 = new ComparisonPredicate(ComparisonPredicate.EQUAL_OP,
        colRefL_OSupKey, colRefS_PSupKey);
    final AndPredicate predL_P = new AndPredicate(predL_P1, predL_P2);

    Component lastJoiner = ThetaJoinComponentFactory
        .createThetaJoinOperator(Theta_JoinType, LINEITEMS_ORDERSjoin,
            SUPPLIER_PARTSUPPjoin, _queryPlan).setJoinPredicate(predL_P)
        .addOperator(new ProjectOperator(new int[] { 0, 1, 2, 3 })).addOperator(agg);
View Full Code Here

Examples of prefuse.data.expression.AndPredicate

      jj_consume_token(AND);
      r = EqualityExpression();
      if ( l instanceof AndPredicate ) {
          ((AndPredicate)l).add((Predicate)r);
      } else {
          l = new AndPredicate((Predicate)l,(Predicate)r);
      }
    }
       {if (true) return l;}
    throw new Error("Missing return statement in function");
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.