Package htsjdk.samtools
Class SBIIndexMerger
Merges SBI files for parts of a file that have been concatenated.
-
Field Summary
Fields inherited from class htsjdk.samtools.IndexMerger
out, partLengths
-
Constructor Summary
ConstructorsConstructorDescriptionSBIIndexMerger
(OutputStream out, long headerLength) Prepare to merge SBI indexes. -
Method Summary
Modifier and TypeMethodDescriptionvoid
finish
(long dataFileLength) Complete the index, and close the output stream.void
processIndex
(SBIIndex index, long partLength) Add an index for a part of the data file to the merged index.
-
Constructor Details
-
SBIIndexMerger
Prepare to merge SBI indexes.- Parameters:
out
- the stream to write the merged index toheaderLength
- the length of any header that precedes the first part of the data file with an index
-
-
Method Details
-
processIndex
Add an index for a part of the data file to the merged index. This method should be called for each index for the data file parts, in order.- Specified by:
processIndex
in classIndexMerger<SBIIndex>
- Parameters:
index
- the index to mergepartLength
- the length of the part file corresponding to the index, in bytes.
-
finish
public void finish(long dataFileLength) Complete the index, and close the output stream.- Specified by:
finish
in classIndexMerger<SBIIndex>
- Parameters:
dataFileLength
- the length of the total data file, in bytes.
-