Struct bio::alphabets::Alphabet [−][src]
pub struct Alphabet { pub symbols: BitSet, }
Representation of an alphabet.
Fields
symbols: BitSet
Methods
impl Alphabet
[src]
impl Alphabet
pub fn new<'a, T: IntoTextIterator<'a>>(symbols: T) -> Self
[src]
pub fn new<'a, T: IntoTextIterator<'a>>(symbols: T) -> Self
Create new alphabet from given symbols.
pub fn insert(&mut self, a: u8)
[src]
pub fn insert(&mut self, a: u8)
Insert symbol into alphabet.
pub fn is_word<'a, T: IntoTextIterator<'a>>(&self, text: T) -> bool
[src]
pub fn is_word<'a, T: IntoTextIterator<'a>>(&self, text: T) -> bool
Check if given text is a word over the alphabet.
pub fn max_symbol(&self) -> Option<u8>
[src]
pub fn max_symbol(&self) -> Option<u8>
Return lexicographically maximal symbol.
pub fn len(&self) -> usize
[src]
pub fn len(&self) -> usize
Return size of the alphabet.
pub fn is_empty(&self) -> bool
[src]
pub fn is_empty(&self) -> bool
Is this alphabet empty?