Examples of createOperator()


Examples of com.facebook.presto.operator.HashSemiJoinOperator.HashSemiJoinOperatorFactory.createOperator()

        HashSemiJoinOperatorFactory joinOperatorFactory = new HashSemiJoinOperatorFactory(
                2,
                setBuilderOperatorFactory.getSetProvider(),
                probeTypes,
                0);
        Operator joinOperator = joinOperatorFactory.createOperator(driverContext);

        // expected
        MaterializedResult expected = resultBuilder(driverContext.getSession(), concat(probeTypes, ImmutableList.of(BOOLEAN)))
                .row(30, 0, true)
                .row(31, 1, false)
View Full Code Here

Examples of com.facebook.presto.operator.HashSemiJoinOperator.HashSemiJoinOperatorFactory.createOperator()

        HashSemiJoinOperatorFactory joinOperatorFactory = new HashSemiJoinOperatorFactory(
                2,
                setBuilderOperatorFactory.getSetProvider(),
                probeTypes,
                0);
        Operator joinOperator = joinOperatorFactory.createOperator(driverContext);

        // expected
        MaterializedResult expected = resultBuilder(driverContext.getSession(), concat(probeTypes, ImmutableList.of(BOOLEAN)))
                .row(1, true)
                .row(2, true)
View Full Code Here

Examples of com.facebook.presto.operator.HashSemiJoinOperator.HashSemiJoinOperatorFactory.createOperator()

        HashSemiJoinOperatorFactory joinOperatorFactory = new HashSemiJoinOperatorFactory(
                2,
                setBuilderOperatorFactory.getSetProvider(),
                probeTypes,
                0);
        Operator joinOperator = joinOperatorFactory.createOperator(driverContext);

        // expected
        MaterializedResult expected = resultBuilder(driverContext.getSession(), concat(probeTypes, ImmutableList.of(BOOLEAN)))
                .row(0, true)
                .row(null, null)
View Full Code Here

Examples of com.facebook.presto.operator.HashSemiJoinOperator.HashSemiJoinOperatorFactory.createOperator()

        HashSemiJoinOperatorFactory joinOperatorFactory = new HashSemiJoinOperatorFactory(
                2,
                setBuilderOperatorFactory.getSetProvider(),
                probeTypes,
                0);
        Operator joinOperator = joinOperatorFactory.createOperator(driverContext);

        // expected
        MaterializedResult expected = resultBuilder(driverContext.getSession(), concat(probeTypes, ImmutableList.of(BOOLEAN)))
                .row(0, true)
                .row(null, null)
View Full Code Here

Examples of com.facebook.presto.operator.LimitOperator.LimitOperatorFactory.createOperator()

                .addSequencePage(2, 4)
                .addSequencePage(2, 6)
                .build();

        OperatorFactory operatorFactory = new LimitOperatorFactory(0, ImmutableList.of(BIGINT), 5);
        Operator operator = operatorFactory.createOperator(driverContext);

        List<Page> expected = rowPagesBuilder(BIGINT)
                .addSequencePage(3, 1)
                .addSequencePage(2, 4)
                .build();
View Full Code Here

Examples of com.facebook.presto.operator.LimitOperator.LimitOperatorFactory.createOperator()

                .addSequencePage(2, 4)
                .addSequencePage(2, 6)
                .build();

        OperatorFactory operatorFactory = new LimitOperatorFactory(0, ImmutableList.of(BIGINT), 6);
        Operator operator = operatorFactory.createOperator(driverContext);

        List<Page> expected = rowPagesBuilder(BIGINT)
                .addSequencePage(3, 1)
                .addSequencePage(2, 4)
                .addSequencePage(1, 6)
View Full Code Here

Examples of com.facebook.presto.operator.MarkDistinctOperator.MarkDistinctOperatorFactory.createOperator()

                .addSequencePage(100, 0)
                .addSequencePage(100, 0)
                .build();

        OperatorFactory operatorFactory = new MarkDistinctOperatorFactory(0, ImmutableList.of(BIGINT), ImmutableList.of(0));
        Operator operator = operatorFactory.createOperator(driverContext);

        MaterializedResult.Builder expected = resultBuilder(driverContext.getSession(), BIGINT, BOOLEAN);
        for (int i = 0; i < 100; i++) {
            expected.row(i, true);
            expected.row(i, false);
View Full Code Here

Examples of com.facebook.presto.operator.MaterializeSampleOperator.MaterializeSampleOperatorFactory.createOperator()

                .addSequencePage(100, 1)
                .build();
        input = appendSampleWeight(input, 0);

        OperatorFactory operatorFactory = new MaterializeSampleOperatorFactory(0, ImmutableList.of(BIGINT), 1);
        Operator operator = operatorFactory.createOperator(driverContext);

        MaterializedResult expected = resultBuilder(driverContext.getSession(), BIGINT)
                .build();

        OperatorAssertion.assertOperatorEqualsIgnoreOrder(operator, input, expected);
View Full Code Here

Examples of com.facebook.presto.operator.OperatorFactory.createOperator()

                session
        );

        OperatorFactory operatorFactory = new FilterAndProjectOperator.FilterAndProjectOperatorFactory(0, new GenericPageProcessor(filterFunction, ImmutableList.of(projectionFunction)), toTypes(
                ImmutableList.of(projectionFunction)));
        return operatorFactory.createOperator(createDriverContext(session));
    }

    private OperatorFactory compileFilterWithNoInputColumns(Expression filter, ExpressionCompiler compiler)
    {
        filter = ExpressionTreeRewriter.rewriteWith(new SymbolToInputRewriter(ImmutableMap.<Symbol, Integer>of()), filter);
View Full Code Here

Examples of com.facebook.presto.operator.OrderByOperator.InMemoryOrderByOperatorFactory.createOperator()

                ImmutableList.of(SINGLE_LONG, SINGLE_DOUBLE),
                0,
                new int[] {1},
                10);

        Operator operator = operatorFactory.createOperator(driverContext);

        MaterializedResult expected = resultBuilder(DOUBLE)
                .row(-0.1)
                .row(0.1)
                .row(0.2)
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.