[−][src]Struct bam::record::Flag
A wrapper around BAM/SAM flag.
You can check flag as record.flag().is_paired()
or record.flag().0 | IS_PAIRED == 0
.
You can also modify the flag as record.flag_mut().set_paired(true)
or
record.flag_mut().0 |= IS_PAIRED
.
Methods
impl Flag
[src]
pub fn is_paired(&self) -> bool
[src]
pub fn all_segments_aligned(&self) -> bool
[src]
pub fn is_mapped(&self) -> bool
[src]
pub fn mate_is_mapped(&self) -> bool
[src]
pub fn is_reverse_strand(&self) -> bool
[src]
pub fn mate_is_reverse_strand(&self) -> bool
[src]
pub fn first_in_pair(&self) -> bool
[src]
pub fn last_in_pair(&self) -> bool
[src]
pub fn is_secondary(&self) -> bool
[src]
pub fn fails_quality_controls(&self) -> bool
[src]
Returns true
if the record fails filters, such as platform/vendor quality controls.
pub fn is_duplicate(&self) -> bool
[src]
Returns true
if the record is PCR or optical duplicate.
pub fn is_supplementary(&self) -> bool
[src]
pub fn set_paired(&mut self, paired: bool)
[src]
Modifies the record flag. This function does not do any checks.
pub fn set_all_segments_aligned(&mut self, all_segments_aligned: bool)
[src]
Modifies the record flag. This function does not do any checks.
pub fn set_mapped(&mut self, mapped: bool)
[src]
Modifies the record flag. This function does not do any checks.
pub fn set_mate_mapped(&mut self, mate_mapped: bool)
[src]
Modifies the record flag. This function does not do any checks and does not modify the mate record.
pub fn set_strand(&mut self, forward_strand: bool)
[src]
Sets the record strand. Use true
to set to forward strand, and false
for the
reverse strand.
pub fn set_mate_strand(&mut self, forward_strand: bool)
[src]
Sets the strand of the mate. Use true
to set to forward strand, and false
for the
reverse strand. This function does not do any checks and does not modify the
mate record.
pub fn set_first_in_pair(&mut self, is_first: bool)
[src]
Modifies the record flag. This function does not do any checks.
Use true
to set the flag bit and false
to unset.
pub fn set_last_in_pair(&mut self, is_last: bool)
[src]
Modifies the record flag. This function does not do any checks.
Use true
to set the flag bit and false
to unset.
pub fn set_secondary(&mut self, is_secondary: bool)
[src]
Modifies the record flag. This function does not do any checks.
Use true
to set the flag bit and false
to unset.
pub fn make_fail_quality_controls(&mut self, fails: bool)
[src]
Sets the record flag to fail or pass filters, such as platform/vendor quality controls.
Use true
to set the flag bit and false
to unset.
pub fn set_duplicate(&mut self, is_duplicate: bool)
[src]
Sets the record as PCR or optical duplicate.
pub fn set_supplementary(&mut self, is_supplementary: bool)
[src]
Trait Implementations
Auto Trait Implementations
impl Send for Flag
impl Sync for Flag
impl Unpin for Flag
impl UnwindSafe for Flag
impl RefUnwindSafe for Flag
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,