static Object nextValue(ColumnVector vector,
                          int row,
                          TypeDescription schema,
                          Object previous) {
    switch (schema.getCategory()) {
      case BOOLEAN:
        return nextBoolean(vector, row, previous);
      case BYTE:
        return nextByte(vector, row, previous);
      case SHORT:
        return nextShort(vector, row, previous);
      case INT:
        return nextInt(vector, row, previous);
      case LONG:
        return nextLong(vector, row, previous);
      case FLOAT:
        return nextFloat(vector, row, previous);
      case DOUBLE:
        return nextDouble(vector, row, previous);
      case STRING:
        return nextString(vector, row, previous);
      case CHAR:
        return nextChar(vector, row, schema.getMaxLength(), previous);
      case VARCHAR:
        return nextVarchar(vector, row, schema.getMaxLength(), previous);
      case BINARY:
        return nextBinary(vector, row, previous);
      case DECIMAL:
        return nextDecimal(vector, row, previous);
      case DATE:
        return nextDate(vector, row, previous);
      case TIMESTAMP:
        return nextTimestamp(vector, row, previous);
      case STRUCT:
        return nextStruct(vector, row, schema, previous);
      case UNION:
        return nextUnion(vector, row, schema, previous);
      case LIST:
        return nextList(vector, row, schema, previous);
      case MAP:
        return nextMap(vector, row, schema, previous);
      default:
        throw new IllegalArgumentException("Unknown type " + schema);
    }
  }
If the current batch is empty, get a new one.
@return true if we have rows available.
@throws IOException
ql/src/java/org/apache/hadoop/hive/ql/io/orc/RecordReaderImpl.java