public class FilteringSamIterator extends java.lang.Object implements CloseableIterator<SAMRecord>
| Constructor and Description |
|---|
FilteringSamIterator(java.util.Iterator<SAMRecord> iterator,
SamRecordFilter filter)
Constructor
|
FilteringSamIterator(java.util.Iterator<SAMRecord> iterator,
SamRecordFilter filter,
boolean filterByPair)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Should be implemented to close/release any underlying resources.
|
boolean |
hasNext()
Returns true if the iteration has more elements.
|
SAMRecord |
next()
Returns the next element in the iteration.
|
void |
remove()
Required method for Iterator API.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitstream, toListpublic FilteringSamIterator(java.util.Iterator<SAMRecord> iterator, SamRecordFilter filter, boolean filterByPair)
iterator - the backing iteratorfilter - the filter (which may be a FilterAggregator)filterByPair - if true, filter reads in pairspublic FilteringSamIterator(java.util.Iterator<SAMRecord> iterator, SamRecordFilter filter)
iterator - the backing iteratorfilter - the filter (which may be a FilterAggregator)public boolean hasNext()
hasNext in interface java.util.Iterator<SAMRecord>public SAMRecord next()
next in interface java.util.Iterator<SAMRecord>java.util.NoSuchElementExceptionpublic void remove()
remove in interface java.util.Iterator<SAMRecord>java.lang.UnsupportedOperationExceptionpublic void close()
CloseableIteratorclose in interface CloseableIterator<SAMRecord>close in interface java.io.Closeableclose in interface java.lang.AutoCloseable