format/src/main/java/com/github/sadikovi/riff/IndexedRowReader.java
/**
   * Read common part of indexed row.
   * Prepare indexed row for both filtered and standard scans. Row already has nullability
   * information and row offsets adjusted.
   * @param in input stream
   * @return initialized indexed row
   * @throws IOException
   */
Read common part of indexed row.
Prepare indexed row for both filtered and standard scans. Row already has nullability
information and row offsets adjusted.
@param in input stream
@return initialized indexed row
@throws IOException
Read common part of indexed row . Prepare indexed row for both filtered and standard scans . Row already has nullability information and row offsets adjusted . @param in input stream @return initialized indexed row @throws IOException
private IndexedRow readRowHeader(InStream in) throws IOException {
    int magic = in.read();
    if (magic != IndexedRow.MAGIC1 && magic != IndexedRow.MAGIC2) {
      throw new AssertionError("Wrong magic number " + magic);
    }
    long nulls = (magic == IndexedRow.MAGIC1) ? 0L : in.readLong();
    return new IndexedRow(this.indexed, nulls, rowOffsets(nulls));
  }
private IndexedRow readRowHeader ( InStream in ) throws IOException { int magic = in . read ( ) ; if ( magic != IndexedRow . MAGIC1 && magic != IndexedRow . MAGIC2 ) { throw new AssertionError ( "Wrong magic number " + magic ) ; } long nulls = ( magic == IndexedRow . MAGIC1 ) ? 0L : in . readLong ( ) ; return new IndexedRow ( this . indexed , nulls , rowOffsets ( nulls ) ) ; }
Read common part of indexed row.
Read common part of indexed row .
// magic is an indicator of nullability in this case. Which means it will either magic1 or // magic2, otherwise we raise assertion error (&& check) // prepare row, compute row offsets