Trait lightmotif::abc::Alphabet

source ·
pub trait Alphabet: Debug + Copy + Default + 'static {
    type Symbol: Symbol + Debug;
    type K: Unsigned + NonZero + ArrayLength + Debug;

    // Required methods
    fn symbols() -> &'static [Self::Symbol];
    fn as_str() -> &'static str;

    // Provided method
    fn default_symbol() -> Self::Symbol { ... }
}
Expand description

A biological alphabet with associated metadata.

Required Associated Types§

Required Methods§

source

fn symbols() -> &'static [Self::Symbol]

Get all the symbols of this alphabet.

source

fn as_str() -> &'static str

Get a string with all symbols from this alphabet.

Provided Methods§

source

fn default_symbol() -> Self::Symbol

Get the default symbol for this alphabet.

Object Safety§

This trait is not object safe.

Implementors§