pub struct IndexedReader { /* private fields */ }
Expand description
An indexed VCF/BCF reader.
Implementations§
Source§impl IndexedReader
impl IndexedReader
Sourcepub fn fetch(&mut self, rid: u32, start: u64, end: Option<u64>) -> Result<()>
pub fn fetch(&mut self, rid: u32, start: u64, end: Option<u64>) -> Result<()>
Jump to the given region.
§Arguments
rid
- numeric ID of the reference to jump to; useHeaderView::name2rid
for resolving contig name to ID.start
-0
-based inclusive start coordinate of region on reference.end
- Optional0
-based inclusive end coordinate of region on reference. IfNone
is given, records are fetched fromstart
until the end of the contig.
§Note
The entire contig can be fetched by setting start
to 0
and end
to None
.
Trait Implementations§
Source§impl Debug for IndexedReader
impl Debug for IndexedReader
Source§impl Drop for IndexedReader
impl Drop for IndexedReader
Source§impl Read for IndexedReader
impl Read for IndexedReader
Source§fn records(&mut self) -> Records<'_, Self> ⓘ
fn records(&mut self) -> Records<'_, Self> ⓘ
Return an iterator over all records of the VCF/BCF file.
Source§fn set_threads(&mut self, n_threads: usize) -> Result<()>
fn set_threads(&mut self, n_threads: usize) -> Result<()>
Activate multi-threaded BCF/VCF read support in htslib. This should permit faster
reading of large VCF files. Read more
Source§fn header(&self) -> &HeaderView
fn header(&self) -> &HeaderView
Return the header.
Source§fn empty_record(&self) -> Record
fn empty_record(&self) -> Record
Return empty record. Can be reused multiple times.
impl Send for IndexedReader
Auto Trait Implementations§
impl Freeze for IndexedReader
impl RefUnwindSafe for IndexedReader
impl !Sync for IndexedReader
impl Unpin for IndexedReader
impl UnwindSafe for IndexedReader
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more