[−][src]Trait debruijn::Mer
Trait for interacting with DNA sequences
Required methods
fn len(&self) -> usize
Length of DNA sequence
fn get(&self, pos: usize) -> u8
Get 2-bit encoded base at position pos
fn set_mut(&mut self, pos: usize, val: u8)
Set base at pos to 2-bit encoded base val
fn set_slice_mut(&mut self, pos: usize, nbases: usize, value: u64)
Set nbases positions in the sequence, starting at pos.
Values must be packed into the upper-most bits of value.
fn rc(&self) -> Self
Return a new object containing the reverse complement of the sequence
Provided methods
ⓘImportant traits for MerIter<'a, M>fn iter<'a>(&'a self) -> MerIter<'a, Self>
Iterate over the bases in the sequence
Implementors
impl Mer for DnaString[src]
fn len(&self) -> usize[src]
fn get(&self, i: usize) -> u8[src]
Get the value at position i.
fn set_mut(&mut self, i: usize, value: u8)[src]
Set the value as position i.
fn set_slice_mut(&mut self, _: usize, _: usize, _: u64)[src]
fn rc(&self) -> DnaString[src]
ⓘImportant traits for MerIter<'a, M>fn iter<'a>(&'a self) -> MerIter<'a, Self>[src]
impl Mer for DnaBytes[src]
fn len(&self) -> usize[src]
fn get(&self, pos: usize) -> u8[src]
fn set_mut(&mut self, pos: usize, val: u8)[src]
Set base at pos to 2-bit encoded base val
fn set_slice_mut(&mut self, _pos: usize, _nbases: usize, _value: u64)[src]
Set nbases positions in the sequence, starting at pos.
Values must be packed into the upper-most bits of value.
fn rc(&self) -> Self[src]
Return a new object containing the reverse complement of the sequence
ⓘImportant traits for MerIter<'a, M>fn iter<'a>(&'a self) -> MerIter<'a, Self>[src]
impl<'a> Mer for DnaStringSlice<'a>[src]
fn len(&self) -> usize[src]
fn get(&self, i: usize) -> u8[src]
Get the base at position i.
fn set_mut(&mut self, _: usize, _: u8)[src]
Set the base as position i.
fn set_slice_mut(&mut self, _: usize, _: usize, _: u64)[src]
fn rc(&self) -> DnaStringSlice<'a>[src]
ⓘImportant traits for MerIter<'a, M>fn iter<'a>(&'a self) -> MerIter<'a, Self>[src]
impl<'a> Mer for DnaSlice<'a>[src]
fn len(&self) -> usize[src]
fn get(&self, pos: usize) -> u8[src]
fn set_mut(&mut self, _pos: usize, _val: u8)[src]
Set base at pos to 2-bit encoded base val
fn set_slice_mut(&mut self, _pos: usize, _nbases: usize, _value: u64)[src]
Set nbases positions in the sequence, starting at pos.
Values must be packed into the upper-most bits of value.
fn rc(&self) -> Self[src]
Return a new object containing the reverse complement of the sequence
ⓘImportant traits for MerIter<'a, M>fn iter<'a>(&'a self) -> MerIter<'a, Self>[src]
impl<A: Array<Item = u64> + Copy + Eq + Ord + Hash> Mer for Lmer<A>[src]
fn len(&self) -> usize[src]
The length of the DNA string
fn get(&self, pos: usize) -> u8[src]
Get the base at position pos
fn set_mut(&mut self, pos: usize, val: u8)[src]
Return a new Lmer with position pos set to base val
fn set_slice_mut(&mut self, pos: usize, n_bases: usize, value: u64)[src]
fn rc(&self) -> Self[src]
ⓘImportant traits for MerIter<'a, M>fn iter<'a>(&'a self) -> MerIter<'a, Self>[src]
impl<T: PrimInt + FromPrimitive + Hash + IntHelp> Mer for IntKmer<T>[src]
fn len(&self) -> usize[src]
fn get(&self, pos: usize) -> u8[src]
Get the letter at the given position.
fn set_mut(&mut self, pos: usize, v: u8)[src]
fn set_slice_mut(&mut self, pos: usize, n_bases: usize, value: u64)[src]
Set a slice of bases in the kmer, using the packed representation in value. Sets n_bases, starting at pos. Bases must always be packed into the upper-most bits of the value.
fn rc(&self) -> Self[src]
Return the reverse complement of this kmer
ⓘImportant traits for MerIter<'a, M>fn iter<'a>(&'a self) -> MerIter<'a, Self>[src]
impl<T: PrimInt + FromPrimitive + Hash + IntHelp, KS: KmerSize> Mer for VarIntKmer<T, KS>[src]
fn len(&self) -> usize[src]
fn get(&self, pos: usize) -> u8[src]
Get the letter at the given position.
fn set_mut(&mut self, pos: usize, v: u8)[src]
fn set_slice_mut(&mut self, pos: usize, n_bases: usize, value: u64)[src]
Set a slice of bases in the kmer, using the packed representation in value. Sets n_bases, starting at pos. Incoming bases must always be packed into the upper-most bits of the value.
fn rc(&self) -> Self[src]
Return the reverse complement of this kmer