Package htsjdk.samtools
Interface BAMIndex
- All Superinterfaces:
AutoCloseable
,Closeable
- All Known Subinterfaces:
BrowseableBAMIndex
- All Known Implementing Classes:
AbstractBAMFileIndex
,CSIIndex
,DiskBasedBAMFileIndex
,SRAIndex
A basic interface for querying BAM indices.
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
Deprecated.static final String
Deprecated.since June 2019 UseFileExtensions.BAI_INDEX
instead.static final String
Deprecated.since June 2019 UseFileExtensions.CSI
instead. -
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
Close the index and release any associated resources.getMetaData
(int reference) Gets meta data for the given reference including information about number of aligned, unaligned, and noCoordinate recordsgetSpanOverlapping
(int referenceIndex, int startPos, int endPos) Gets the compressed chunks which should be searched for the contents of records contained by the span referenceIndex:startPos-endPos, inclusive.long
Gets the start of the last linear bin in the index.
-
Field Details
-
BAMIndexSuffix
Deprecated.since June 2019 UseFileExtensions.BAI_INDEX
instead.- See Also:
-
BAI_INDEX_SUFFIX
Deprecated.since June 2019 UseFileExtensions.BAI_INDEX
instead.- See Also:
-
CSI_INDEX_SUFFIX
Deprecated.since June 2019 UseFileExtensions.CSI
instead.- See Also:
-
-
Method Details
-
getSpanOverlapping
Gets the compressed chunks which should be searched for the contents of records contained by the span referenceIndex:startPos-endPos, inclusive. See the BAM spec for more information on how a chunk is represented.- Parameters:
referenceIndex
- The contig.startPos
- Genomic start of query.endPos
- Genomic end of query.- Returns:
- A file span listing the chunks in the BAM file.
-
getStartOfLastLinearBin
long getStartOfLastLinearBin()Gets the start of the last linear bin in the index.- Returns:
- The chunk indicating the start of the last bin in the linear index.
-
getMetaData
Gets meta data for the given reference including information about number of aligned, unaligned, and noCoordinate records- Parameters:
reference
- the reference of interest- Returns:
- meta data for the reference
-
close
void close()Close the index and release any associated resources.- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
-
FileExtensions.BAI_INDEX
instead.