Examples of createOperator()


Examples of com.esterel.scade.api.ScadeFactory.createOperator()

    Package1.setName("Package1");
   
    mainModel.getPackage().add(Package1);
    resourcePackage1.getContents().add(Package1);
   
    com.esterel.scade.api.Operator Operator1 = theScadeFactory.createOperator();
    Operator1.setName("Operator1");
    Operator1.setKind(OperatorKind.NODE_LITERAL);
    Package1.getDeclaration().add(Operator1);
   
    com.esterel.scade.api.Variable Operator1_Input1 = theScadeFactory.createVariable();
View Full Code Here

Examples of com.facebook.presto.operator.AggregationOperator.AggregationOperatorFactory.createOperator()

                        VAR_BINARY_MAX.bind(ImmutableList.of(2), Optional.<Integer>absent(), Optional.<Integer>absent(), 1.0),
                        countVarcharColumn.bind(ImmutableList.of(0), Optional.<Integer>absent(), Optional.<Integer>absent(), 1.0),
                        LONG_SUM.bind(ImmutableList.of(3), Optional.<Integer>absent(), Optional.<Integer>absent(), 1.0),
                        DOUBLE_SUM.bind(ImmutableList.of(4), Optional.<Integer>absent(), Optional.<Integer>absent(), 1.0),
                        VAR_BINARY_MAX.bind(ImmutableList.of(5), Optional.<Integer>absent(), Optional.<Integer>absent(), 1.0)));
        Operator operator = operatorFactory.createOperator(driverContext);

        MaterializedResult expected = resultBuilder(driverContext.getSession(), BIGINT, BIGINT, DOUBLE, VARCHAR, BIGINT, BIGINT, DOUBLE, VARCHAR)
                .row(100, 4950, 49.5, "399", 100, 54950, 54950.0, "599")
                .build();
View Full Code Here

Examples of com.facebook.presto.operator.AlignmentOperator.AlignmentOperatorFactory.createOperator()

        assertTrue(storageManager.shardExists(shardUuid));

        AlignmentOperatorFactory factory = new AlignmentOperatorFactory(0,
                storageManager.getBlocks(shardUuid, columnHandles.get(0)),
                storageManager.getBlocks(shardUuid, columnHandles.get(1)));
        Operator operator = factory.createOperator(driverContext);

        // materialize pages to force comparision only on contents and not page boundaries
        MaterializedResult expected = toMaterializedResult(operator.getOperatorContext().getSession(), operator.getTypes(), pages);

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

Examples of com.facebook.presto.operator.ExchangeOperator.ExchangeOperatorFactory.createOperator()

        DriverContext driverContext = new TaskContext(new TaskId("query", "stage", "task"), executor, TEST_SESSION)
                .addPipelineContext(true, true)
                .addDriverContext();

        return operatorFactory.createOperator(driverContext);
    }

    private List<Page> waitForPages(Operator operator, int expectedPageCount)
            throws InterruptedException
    {
View Full Code Here

Examples of com.facebook.presto.operator.FilterAndProjectOperator.FilterAndProjectOperatorFactory.createOperator()

                metadataManager,
                session
        );

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

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

Examples of com.facebook.presto.operator.HashAggregationOperator.HashAggregationOperatorFactory.createOperator()

                        VAR_BINARY_MAX.bind(ImmutableList.of(2), Optional.<Integer>absent(), Optional.<Integer>absent(), 1.0),
                        countVarcharColumn.bind(ImmutableList.of(0), Optional.<Integer>absent(), Optional.<Integer>absent(), 1.0),
                        countBooleanColumn.bind(ImmutableList.of(4), Optional.<Integer>absent(), Optional.<Integer>absent(), 1.0)),
                100_000);

        Operator operator = operatorFactory.createOperator(driverContext);

        MaterializedResult expected = resultBuilder(driverContext.getSession(), VARCHAR, BIGINT, BIGINT, DOUBLE, VARCHAR, BIGINT, BIGINT)
                .row("0", 3, 0, 0.0, "300", 3, 3)
                .row("1", 3, 3, 1.0, "301", 3, 3)
                .row("2", 3, 6, 2.0, "302", 3, 3)
View Full Code Here

Examples of com.facebook.presto.operator.HashAggregationOperator.HashAggregationOperatorFactory.createOperator()

                        LONG_SUM.bind(ImmutableList.of(3), Optional.<Integer>absent(), Optional.<Integer>absent(), 1.0),
                        LONG_AVERAGE.bind(ImmutableList.of(3), Optional.<Integer>absent(), Optional.<Integer>absent(), 1.0),
                        VAR_BINARY_MAX.bind(ImmutableList.of(2), Optional.<Integer>absent(), Optional.<Integer>absent(), 1.0)),
                100_000);

        Operator operator = operatorFactory.createOperator(driverContext);

        toPages(operator, input);
    }

    @Test
View Full Code Here

Examples of com.facebook.presto.operator.HashAggregationOperator.HashAggregationOperatorFactory.createOperator()

                Ints.asList(0),
                Step.SINGLE,
                ImmutableList.of(COUNT.bind(ImmutableList.of(0), Optional.<Integer>absent(), Optional.<Integer>absent(), 1.0)),
                100_000);

        Operator operator = operatorFactory.createOperator(driverContext);

        toPages(operator, input);
    }

    @Test(expectedExceptions = PrestoException.class, expectedExceptionsMessageRegExp = "Task exceeded max memory size of 3MB")
View Full Code Here

Examples of com.facebook.presto.operator.HashAggregationOperator.HashAggregationOperatorFactory.createOperator()

                Ints.asList(0),
                Step.SINGLE,
                ImmutableList.of(COUNT.bind(ImmutableList.of(0), Optional.<Integer>absent(), Optional.<Integer>absent(), 1.0)),
                100_000);

        Operator operator = operatorFactory.createOperator(driverContext);

        toPages(operator, input);
    }

    @Test
View Full Code Here

Examples of com.facebook.presto.operator.HashAggregationOperator.HashAggregationOperatorFactory.createOperator()

                Step.SINGLE,
                ImmutableList.of(COUNT.bind(ImmutableList.of(0), Optional.<Integer>absent(), Optional.<Integer>absent(), 1.0),
                        LONG_AVERAGE.bind(ImmutableList.of(1), Optional.<Integer>absent(), Optional.<Integer>absent(), 1.0)),
                100_000);

        Operator operator = operatorFactory.createOperator(driverContext);

        assertEquals(toPages(operator, input).size(), 2);
    }

    @Test
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.