Accidental

Trait Accidental 

Source
pub trait Accidental:
    'static
    + AsRef<str>
    + Send
    + Sync
    + Debug
    + Display {
    // Required methods
    fn new() -> Self
       where Self: Sized;
    fn name(&self) -> &str;
    fn symbol(&self) -> char;

    // Provided method
    fn from_str(s: &str) -> Result<Self, Error>
       where Self: Sized + FromStr<Err = Error> { ... }
}
Expand description

Accidental is a sealed marker trait used to designate various kinds of musical notes, i.e., sharp, flat, natural, etc.

Required Methods§

Source

fn new() -> Self
where Self: Sized,

Source

fn name(&self) -> &str

Source

fn symbol(&self) -> char

Provided Methods§

Source

fn from_str(s: &str) -> Result<Self, Error>
where Self: Sized + FromStr<Err = Error>,

Implementors§