Examples of TList


Examples of org.apache.thrift.protocol.TList

   * calling this method again.
   */
  @Override
  public TList readListBegin() throws TException {
    stackLevel++;
    tlist = new TList(ORDERED_TYPE, readI32());
    if (tlist.size == 0 && lastPrimitiveWasNull()) {
      return null;
    }
    return tlist;
  }
View Full Code Here

Examples of org.apache.thrift.protocol.TList

  }

  @Override
  public TList readListBegin() throws TException {
    assert (!inner);
    TList list = new TList();
    if (columns[index] == null || columns[index].equals(nullString)) {
      index++;
      if (returnNulls) {
        return null;
      }
    } else if (columns[index].isEmpty()) {
      index++;
    } else {
      fields = secondaryPattern.split(columns[index++]);
      list = new TList(ORDERED_TYPE, fields.length);
    }
    innerIndex = 0;
    inner = true;
    return list;
  }
View Full Code Here

Examples of org.apache.thrift.protocol.TList

    }

    public boolean[] readBoolArray()
            throws TException
    {
        TList list = protocol.readListBegin();
        boolean[] array = new boolean[list.size];
        for (int i = 0; i < list.size; i++) {
            array[i] = readBool();
        }
        protocol.readListEnd();
View Full Code Here

Examples of org.apache.thrift.protocol.TList

    }

    public short[] readI16Array()
            throws TException
    {
        TList list = protocol.readListBegin();
        short[] array = new short[list.size];
        for (int i = 0; i < list.size; i++) {
            array[i] = readI16();
        }
        protocol.readListEnd();
View Full Code Here

Examples of org.apache.thrift.protocol.TList

    }

    public int[] readI32Array()
            throws TException
    {
        TList list = protocol.readListBegin();
        int[] array = new int[list.size];
        for (int i = 0; i < list.size; i++) {
            array[i] = readI32();
        }
        protocol.readListEnd();
View Full Code Here

Examples of org.apache.thrift.protocol.TList

    }

    public long[] readI64Array()
            throws TException
    {
        TList list = protocol.readListBegin();
        long[] array = new long[list.size];
        for (int i = 0; i < list.size; i++) {
            array[i] = readI64();
        }
        protocol.readListEnd();
View Full Code Here

Examples of org.apache.thrift.protocol.TList

    }

    public double[] readDoubleArray()
            throws TException
    {
        TList list = protocol.readListBegin();
        double[] array = new double[list.size];
        for (int i = 0; i < list.size; i++) {
            array[i] = readDouble();
        }
        protocol.readListEnd();
View Full Code Here

Examples of org.apache.thrift.protocol.TList

    }

    public <E> List<E> readList(ThriftCodec<E> elementCodec)
            throws Exception
    {
        TList tList = protocol.readListBegin();
        List<E> list = new ArrayList<>();
        for (int i = 0; i < tList.size; i++) {
            try {
                E element = elementCodec.read(protocol);
                list.add(element);
View Full Code Here

Examples of org.apache.thrift.protocol.TList

    }

    public void writeBoolArray(boolean[] array)
            throws TException
    {
        protocol.writeListBegin(new TList(TType.BOOL, array.length));
        for (boolean booleanValue : array) {
            writeBool(booleanValue);
        }
        protocol.writeListEnd();
    }
View Full Code Here

Examples of org.apache.thrift.protocol.TList

    }

    public void writeI16Array(short[] array)
            throws TException
    {
        protocol.writeListBegin(new TList(TType.I16, array.length));
        for (int i16 : array) {
            writeI32(i16);
        }
        protocol.writeListEnd();
    }
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.