private static int countMaxStreams(Area area) {
    int count = 0;
    for (Stream.Kind sk : Stream.Kind.values()) {
      if (StreamName.getArea(sk) == area) {
        ++count;
      }
    }
    return count;
  }
Estimate the RowGroup offset given the next RG offset and isLast.

@param isCompressed is the RowGroup compressed
@param isLast is this the last RowGroup
@param nextGroupOffset the offset of the next RowGroup
@param streamLength the length of the whole Stream
@param bufferSize the size of the buffer
@return
ql/src/java/org/apache/hadoop/hive/ql/io/orc/encoded/EncodedReaderImpl.java