Package htsjdk.samtools.cram.build
Class CramContainerIterator
- java.lang.Object
-
- htsjdk.samtools.cram.build.CramContainerIterator
-
- All Implemented Interfaces:
Closeable,AutoCloseable,Iterator<Container>
- Direct Known Subclasses:
CramContainerHeaderIterator,CramSpanContainerIterator
public class CramContainerIterator extends Object implements Iterator<Container>, Closeable
An iterator of CRAM containers read from anInputStream.
-
-
Constructor Summary
Constructors Constructor Description CramContainerIterator(InputStream inputStream)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()protected ContainercontainerFromStream(CountingInputStream countingStream)Consume the entirety of the next container from the stream.CramHeadergetCramHeader()SAMFileHeadergetSamFileHeader()booleanhasNext()Containernext()voidremove()-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface java.util.Iterator
forEachRemaining
-
-
-
-
Constructor Detail
-
CramContainerIterator
public CramContainerIterator(InputStream inputStream)
-
-
Method Detail
-
containerFromStream
protected Container containerFromStream(CountingInputStream countingStream)
Consume the entirety of the next container from the stream.- Parameters:
countingStream- theCountingInputStreamto read from- Returns:
- The next Container from the stream.
- See Also:
containerFromStream(CountingInputStream)
-
getCramHeader
public CramHeader getCramHeader()
-
getSamFileHeader
public SAMFileHeader getSamFileHeader()
-
close
public void close()
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable
-
-