public final void storeRecord(byte[] data) throws IOException {
  long spareSlots=maxRecords.get() - recordCount.get();
  if (spareSlots > 0L) {
    storeRecordInternal(data);
    recordCount.incrementAndGet();
  }
 else   if (spareSlots == 0L) {
    recordCount.incrementAndGet();
  }
}

public final void storeRecord ( byte [ ] data ) throws IOException { long spareSlots = maxRecords . get ( ) - recordCount . get ( ) ; if ( spareSlots > 0L ) { storeRecordInternal ( data ) ; recordCount . incrementAndGet ( ) ; } else if ( spareSlots == 0L ) { recordCount . incrementAndGet ( ) ; } }
stores a record in the cache .
