/** Removes the next record from this buffer */ public void remove() { this.next(); }
/** Removes the next record from this buffer */ public void remove() { this.next(); }
/** * Gets a SAMRecord if one is available after marking. This enforces that we return records in the original * coordinate sort order in a stable fashion. * * @return record representing the head of the alignment-start sorted buffer, or null if the head record has not yet been duplicate marked */ private SAMRecord flush() { // Check that there is at least one record in the coordinate-sorted buffer, and that the head record has been through duplicate-marking while (!outputBuffer.isEmpty() && outputBuffer.canEmit()) { // the buffer contains wrapped SAMRecords, which we want to unwrap final SAMRecord record = outputBuffer.next().getRecord(); // If this read is a duplicate, do we want to remove it (continue the loop) or return it for emission? if (!removeDuplicates || !record.getDuplicateReadFlag()) { return record; } } return null; }
/** * Gets a SAMRecord if one is available after marking. This enforces that we return records in the original * coordinate sort order in a stable fashion. * * @return record representing the head of the alignment-start sorted buffer, or null if the head record has not yet been duplicate marked */ private SAMRecord flush() { // Check that there is at least one record in the coordinate-sorted buffer, and that the head record has been through duplicate-marking while (!outputBuffer.isEmpty() && outputBuffer.canEmit()) { // the buffer contains wrapped SAMRecords, which we want to unwrap final SAMRecord record = outputBuffer.next().getRecord(); // If this read is a duplicate, do we want to remove it (continue the loop) or return it for emission? if (!removeDuplicates || !record.getDuplicateReadFlag()) { return record; } } return null; }