Examples of generateStateFactory()


Examples of com.facebook.presto.operator.aggregation.state.StateCompiler.generateStateFactory()

    @Test
    public void testPrimitiveNullableLongSerialization()
    {
        StateCompiler compiler = new StateCompiler();

        AccumulatorStateFactory<NullableBigintState> factory = compiler.generateStateFactory(NullableBigintState.class);
        AccumulatorStateSerializer<NullableBigintState> serializer = compiler.generateStateSerializer(NullableBigintState.class);
        NullableBigintState state = factory.createSingleState();
        NullableBigintState deserializedState = factory.createSingleState();

        state.setLong(2);
View Full Code Here

Examples of com.facebook.presto.operator.aggregation.state.StateCompiler.generateStateFactory()

    @Test
    public void testPrimitiveLongSerialization()
    {
        StateCompiler compiler = new StateCompiler();

        AccumulatorStateFactory<LongState> factory = compiler.generateStateFactory(LongState.class);
        AccumulatorStateSerializer<LongState> serializer = compiler.generateStateSerializer(LongState.class);
        LongState state = factory.createSingleState();
        LongState deserializedState = factory.createSingleState();

        state.setLong(2);
View Full Code Here

Examples of com.facebook.presto.operator.aggregation.state.StateCompiler.generateStateFactory()

    @Test
    public void testPrimitiveBooleanSerialization()
    {
        StateCompiler compiler = new StateCompiler();

        AccumulatorStateFactory<BooleanState> factory = compiler.generateStateFactory(BooleanState.class);
        AccumulatorStateSerializer<BooleanState> serializer = compiler.generateStateSerializer(BooleanState.class);
        BooleanState state = factory.createSingleState();
        BooleanState deserializedState = factory.createSingleState();

        state.setBoolean(true);
View Full Code Here

Examples of com.facebook.presto.operator.aggregation.state.StateCompiler.generateStateFactory()

    @Test
    public void testPrimitiveByteSerialization()
    {
        StateCompiler compiler = new StateCompiler();

        AccumulatorStateFactory<ByteState> factory = compiler.generateStateFactory(ByteState.class);
        AccumulatorStateSerializer<ByteState> serializer = compiler.generateStateSerializer(ByteState.class);
        ByteState state = factory.createSingleState();
        ByteState deserializedState = factory.createSingleState();

        state.setByte((byte) 3);
View Full Code Here

Examples of com.facebook.presto.operator.aggregation.state.StateCompiler.generateStateFactory()

    @Test
    public void testVarianceStateSerialization()
    {
        StateCompiler compiler = new StateCompiler();

        AccumulatorStateFactory<VarianceState> factory = compiler.generateStateFactory(VarianceState.class);
        AccumulatorStateSerializer<VarianceState> serializer = compiler.generateStateSerializer(VarianceState.class);
        VarianceState singleState = factory.createSingleState();
        VarianceState deserializedState = factory.createSingleState();

        singleState.setMean(1);
View Full Code Here

Examples of com.facebook.presto.operator.aggregation.state.StateCompiler.generateStateFactory()

    @Test
    public void testComplexSerialization()
    {
        StateCompiler compiler = new StateCompiler();

        AccumulatorStateFactory<TestComplexState> factory = compiler.generateStateFactory(TestComplexState.class);
        AccumulatorStateSerializer<TestComplexState> serializer = compiler.generateStateSerializer(TestComplexState.class);
        TestComplexState singleState = factory.createSingleState();
        TestComplexState deserializedState = factory.createSingleState();

        singleState.setBoolean(true);
View Full Code Here

Examples of com.facebook.presto.operator.aggregation.state.StateCompiler.generateStateFactory()

    @Test
    public void testPrimitiveNullableLongSerialization()
    {
        StateCompiler compiler = new StateCompiler();

        AccumulatorStateFactory<NullableLongState> factory = compiler.generateStateFactory(NullableLongState.class);
        AccumulatorStateSerializer<NullableLongState> serializer = compiler.generateStateSerializer(NullableLongState.class);
        NullableLongState state = factory.createSingleState();
        NullableLongState deserializedState = factory.createSingleState();

        state.setLong(2);
View Full Code Here

Examples of com.facebook.presto.operator.aggregation.state.StateCompiler.generateStateFactory()

    @Test
    public void testPrimitiveLongSerialization()
    {
        StateCompiler compiler = new StateCompiler();

        AccumulatorStateFactory<LongState> factory = compiler.generateStateFactory(LongState.class);
        AccumulatorStateSerializer<LongState> serializer = compiler.generateStateSerializer(LongState.class);
        LongState state = factory.createSingleState();
        LongState deserializedState = factory.createSingleState();

        state.setLong(2);
View Full Code Here

Examples of com.facebook.presto.operator.aggregation.state.StateCompiler.generateStateFactory()

    @Test
    public void testPrimitiveBooleanSerialization()
    {
        StateCompiler compiler = new StateCompiler();

        AccumulatorStateFactory<BooleanState> factory = compiler.generateStateFactory(BooleanState.class);
        AccumulatorStateSerializer<BooleanState> serializer = compiler.generateStateSerializer(BooleanState.class);
        BooleanState state = factory.createSingleState();
        BooleanState deserializedState = factory.createSingleState();

        state.setBoolean(true);
View Full Code Here

Examples of com.facebook.presto.operator.aggregation.state.StateCompiler.generateStateFactory()

    @Test
    public void testPrimitiveByteSerialization()
    {
        StateCompiler compiler = new StateCompiler();

        AccumulatorStateFactory<ByteState> factory = compiler.generateStateFactory(ByteState.class);
        AccumulatorStateSerializer<ByteState> serializer = compiler.generateStateSerializer(ByteState.class);
        ByteState state = factory.createSingleState();
        ByteState deserializedState = factory.createSingleState();

        state.setByte((byte) 3);
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.