Class SliceBlocksReadStreams
java.lang.Object
htsjdk.samtools.cram.structure.SliceBlocksReadStreams
Provides a layer over a
SliceBlocks object and acts as a bridge between the DataSeries codecs
and their underlying blocks when reading a CRAM stream by presenting a bit (core) or byte (external) stream
for each block.
External block streams use unsynchronized CRAMByteReader instead of
ByteArrayInputStream to eliminate synchronized method call overhead in the hot decode path.
-
Constructor Summary
ConstructorsConstructorDescriptionSliceBlocksReadStreams(SliceBlocks sliceBlocks, CompressorCache compressorCache) -
Method Summary
Modifier and TypeMethodDescriptionGet theBitInputStreamfor thisSliceBlockscore block.getExternalReader(Integer contentID) Get theCRAMByteReaderfor the given content ID.
-
Constructor Details
-
SliceBlocksReadStreams
- Parameters:
sliceBlocks-SliceBlocksthat have been populated from a CRAM stream
-
-
Method Details
-
getCoreBlockInputStream
Get theBitInputStreamfor thisSliceBlockscore block.- Returns:
BitInputStreamfor the core block
-
getExternalReader
Get theCRAMByteReaderfor the given content ID.- Parameters:
contentID- the external block content ID- Returns:
- CRAMByteReader for the content ID
-