@Override
    public int read(byte[] data, int offset, int length) {
     if (!ensureRangeWithData()) {
        return -1;
      }
      int actualLength = Math.min(length, range.remaining());
      range.get(data, offset, actualLength);
      currentOffset += actualLength;
      return actualLength;
    }
Pool factory that is used if another one isn't specified - just creates the objects.
ql/src/java/org/apache/hadoop/hive/ql/io/orc/encoded/EncodedReaderImpl.java