Package com.facebook.presto.tuple

Examples of com.facebook.presto.tuple.TupleInfo$Builder


        }

        @Override
        public TupleInfo getTupleInfo()
        {
            return new TupleInfo(fieldType);
        }
View Full Code Here


            }

            @Override
            protected Block computeNext()
            {
                BlockBuilder builder = new BlockBuilder(new TupleInfo(fieldType));

                while (!builder.isFull() && cursor.advanceNextPosition()) {
                    switch (fieldType) {
                        case BOOLEAN:
                            builder.append(cursor.getBoolean(fieldIndex));
View Full Code Here

    private static List<TupleInfo> toTupleInfos(List<ColumnType> columnTypes)
    {
        ImmutableList.Builder<TupleInfo> tupleInfos = ImmutableList.builder();
        for (ColumnType columnType : columnTypes) {
            tupleInfos.add(new TupleInfo(fromColumnType(columnType)));
        }
        return tupleInfos.build();
    }
View Full Code Here

                .transform(new Function<TupleInfo.Type, TupleInfo>()
                {
                    @Override
                    public TupleInfo apply(TupleInfo.Type input)
                    {
                        return new TupleInfo(input);
                    }
                })
                .list();

        ImmutableList.Builder<PlanNode> sources = ImmutableList.builder();
View Full Code Here

        BlockCursor[] cursors = new BlockCursor[page.getChannelCount()];
        Type[] types = new Type[page.getChannelCount()];

        for (int channel = 0; channel < cursors.length; channel++) {
            cursors[channel] = page.getBlock(channel).cursor();
            TupleInfo tupleInfo = cursors[channel].getTupleInfo();
            checkArgument(tupleInfo.getFieldCount() == 1, "expected block to have exactly one field");
            types[channel] = tupleInfo.getTypes().get(0);
        }

        int rows = page.getPositionCount();
        for (int position = 0; position < rows; position++) {
            recordSink.beginRecord();
View Full Code Here

                    .transform(new Function<TupleInfo.Type, TupleInfo>()
                    {
                        @Override
                        public TupleInfo apply(TupleInfo.Type input)
                        {
                            return new TupleInfo(input);
                        }
                    })
                    .list());
        }
View Full Code Here

        public Iterator<Page> build()
        {
            List<Type> types = groupByHash.getTypes();
            ImmutableList.Builder<TupleInfo> tupleInfos = ImmutableList.builder();
            for (Type type : types) {
                tupleInfos.add(new TupleInfo(type));
            }
            for (Aggregator aggregator : aggregators) {
                tupleInfos.add(aggregator.getTupleInfo());
            }
View Full Code Here

                    .transform(new Function<TupleInfo.Type, TupleInfo>()
                    {
                        @Override
                        public TupleInfo apply(TupleInfo.Type input)
                        {
                            return new TupleInfo(input);
                        }
                    })
                    .list());
        }
View Full Code Here

        public Iterator<Page> build()
        {
            List<Type> types = groupByHash.getTypes();
            ImmutableList.Builder<TupleInfo> tupleInfos = ImmutableList.builder();
            for (Type type : types) {
                tupleInfos.add(new TupleInfo(type));
            }
            for (Aggregator aggregator : aggregators) {
                tupleInfos.add(aggregator.getTupleInfo());
            }
View Full Code Here

        BlockCursor[] cursors = new BlockCursor[page.getChannelCount()];
        Type[] types = new Type[page.getChannelCount()];

        for (int channel = 0; channel < cursors.length; channel++) {
            cursors[channel] = page.getBlock(channel).cursor();
            TupleInfo tupleInfo = cursors[channel].getTupleInfo();
            types[channel] = tupleInfo.getType();
        }

        int rows = page.getPositionCount();
        for (int position = 0; position < rows; position++) {
            recordSink.beginRecord();
View Full Code Here

TOP

Related Classes of com.facebook.presto.tuple.TupleInfo$Builder

Copyright © 2018 www.massapicom. 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.