pub struct BigBedRead<R> { /* private fields */ }
Expand description
The struct used to read a bigBed file
Implementations§
Source§impl<R> BigBedRead<R>
impl<R> BigBedRead<R>
Sourcepub fn info(&self) -> &BBIFileInfo
pub fn info(&self) -> &BBIFileInfo
Get basic info about this bigBed
Sourcepub fn into_inner(self) -> R
pub fn into_inner(self) -> R
Consumes this BigWigRead
, returning the underlying reader.
Source§impl<R> BigBedRead<R>where
R: SeekableRead,
impl<R> BigBedRead<R>where
R: SeekableRead,
Sourcepub fn cached(self) -> BigBedRead<CachedBBIFileRead<R>>
pub fn cached(self) -> BigBedRead<CachedBBIFileRead<R>>
Converts this BigBedRead`` to where the
BBIFileRead` caches index
access and block data
Source§impl<R: BBIFileRead> BigBedRead<R>
impl<R: BBIFileRead> BigBedRead<R>
Sourcepub fn open(read: R) -> Result<Self, BigBedReadOpenError>
pub fn open(read: R) -> Result<Self, BigBedReadOpenError>
Opens a new BigBedRead
for a given type that implements both Read
and Seek
Sourcepub fn with_info(info: BBIFileInfo, read: R) -> Self
pub fn with_info(info: BBIFileInfo, read: R) -> Self
Does not check if the passed R
matches the provided info (including if the R
is a bigBed at all!)
Sourcepub fn autosql(&mut self) -> Result<Option<String>, BBIReadError>
pub fn autosql(&mut self) -> Result<Option<String>, BBIReadError>
Reads the autosql from this bigBed
pub fn item_count(&mut self) -> Result<u64, BBIReadError>
Sourcepub fn inner_read(&self) -> &R
pub fn inner_read(&self) -> &R
Gets a reference to the inner R
type, in order to access any info
Sourcepub fn get_summary(&mut self) -> Result<Summary>
pub fn get_summary(&mut self) -> Result<Summary>
Returns the summary data from bigBed
Note: For version 1 of bigBeds, there is no total summary. In that
case, 0 is returned for all of the summary except total items. If this
matters to you, you can check the version using
info().header.version > 1
.
Sourcepub fn get_interval<'a>(
&'a mut self,
chrom_name: &str,
start: u32,
end: u32,
) -> Result<BigBedIntervalIter<R, &'a mut BigBedRead<R>>, BBIReadError>
pub fn get_interval<'a>( &'a mut self, chrom_name: &str, start: u32, end: u32, ) -> Result<BigBedIntervalIter<R, &'a mut BigBedRead<R>>, BBIReadError>
For a given chromosome, start, and end, returns an Iterator
of the
intersecting BedEntry
s. The resulting iterator takes a mutable reference
of this BigBedRead
.
Sourcepub fn get_interval_move(
self,
chrom_name: &str,
start: u32,
end: u32,
) -> Result<BigBedIntervalIter<R, BigBedRead<R>>, BBIReadError>
pub fn get_interval_move( self, chrom_name: &str, start: u32, end: u32, ) -> Result<BigBedIntervalIter<R, BigBedRead<R>>, BBIReadError>
For a given chromosome, start, and end, returns an Iterator
of the
intersecting BedEntry
s. The resulting iterator takes this BigBedRead
by value.
Sourcepub fn get_zoom_interval<'a>(
&'a mut self,
chrom_name: &str,
start: u32,
end: u32,
reduction_level: u32,
) -> Result<ZoomIntervalIter<BigBedRead<R>, &'a mut BigBedRead<R>>, ZoomIntervalError>
pub fn get_zoom_interval<'a>( &'a mut self, chrom_name: &str, start: u32, end: u32, reduction_level: u32, ) -> Result<ZoomIntervalIter<BigBedRead<R>, &'a mut BigBedRead<R>>, ZoomIntervalError>
For a given chromosome, start, and end, returns an Iterator
of the
intersecting ZoomRecord
s.
Sourcepub fn get_zoom_interval_move<'a>(
self,
chrom_name: &str,
start: u32,
end: u32,
reduction_level: u32,
) -> Result<ZoomIntervalIter<BigBedRead<R>, BigBedRead<R>>, ZoomIntervalError>
pub fn get_zoom_interval_move<'a>( self, chrom_name: &str, start: u32, end: u32, reduction_level: u32, ) -> Result<ZoomIntervalIter<BigBedRead<R>, BigBedRead<R>>, ZoomIntervalError>
For a given chromosome, start, and end, returns an Iterator
of the
intersecting ZoomRecord
s.
Trait Implementations§
Source§impl<R: BBIFileRead> BBIRead for BigBedRead<R>
impl<R: BBIFileRead> BBIRead for BigBedRead<R>
Source§impl<R> Into<BigBedRead<R>> for BigBedIntervalIter<R, BigBedRead<R>>
impl<R> Into<BigBedRead<R>> for BigBedIntervalIter<R, BigBedRead<R>>
Source§fn into(self) -> BigBedRead<R>
fn into(self) -> BigBedRead<R>
Source§impl<R> Into<BigBedRead<R>> for ZoomIntervalIter<BigBedRead<R>, BigBedRead<R>>
impl<R> Into<BigBedRead<R>> for ZoomIntervalIter<BigBedRead<R>, BigBedRead<R>>
Source§fn into(self) -> BigBedRead<R>
fn into(self) -> BigBedRead<R>
Auto Trait Implementations§
impl<R> Freeze for BigBedRead<R>where
R: Freeze,
impl<R> RefUnwindSafe for BigBedRead<R>where
R: RefUnwindSafe,
impl<R> Send for BigBedRead<R>where
R: Send,
impl<R> Sync for BigBedRead<R>where
R: Sync,
impl<R> Unpin for BigBedRead<R>where
R: Unpin,
impl<R> UnwindSafe for BigBedRead<R>where
R: UnwindSafe,
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more