pub struct Note {
pub text: EzStr,
pub accidentals: EzStr,
pub degree: EzStr,
}Fields§
§text: EzStr§accidentals: EzStr§degree: EzStrImplementations§
Source§impl Note
impl Note
pub const fn scale_degree_to_fret_first_octave(degree: u8) -> Option<u8>
pub const fn fret_to_scale_degree_all_sharps(fret: u8) -> Option<u8>
pub const fn fret_to_scale_degree_all_flats(fret: u8) -> Option<u8>
pub fn new<T: Into<EzStr>>(text: T) -> Option<Self>
pub fn accidentals_dist(&self) -> i32
pub fn degree_to_fret<N: Into<u8>>(degree: N) -> i32
pub fn fret(&self) -> i32
pub fn from_fret<F: Into<u8>>(fret: F) -> Note
pub fn unicode_accidentals(&self, using_double_accidentals: bool) -> String
pub fn parse_until_invalid(text: &EzStr, start: usize) -> Option<Note>
Trait Implementations§
impl Eq for Note
Source§impl Extend<Note> for Change
impl Extend<Note> for Change
Source§fn extend<T: IntoIterator<Item = Note>>(&mut self, iter: T)
fn extend<T: IntoIterator<Item = Note>>(&mut self, iter: T)
Extends a collection with the contents of an iterator. Read more
Source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
🔬This is a nightly-only experimental API. (
extend_one)Extends a collection with exactly one element.
Source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
🔬This is a nightly-only experimental API. (
extend_one)Reserves capacity in a collection for the given number of additional elements. Read more
impl StructuralPartialEq for Note
Auto Trait Implementations§
impl !Freeze for Note
impl RefUnwindSafe for Note
impl Send for Note
impl Sync for Note
impl Unpin for Note
impl UnsafeUnpin for Note
impl UnwindSafe for Note
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.