Trait MIDINote

Source
pub trait MIDINote<T: MIDINum>: Debug {
Show 18 methods // Required methods fn start(&self) -> T; fn start_mut(&mut self) -> &mut T; fn len(&self) -> T; fn len_mut(&mut self) -> &mut T; fn key(&self) -> u8; fn key_mut(&mut self) -> &mut u8; fn channel(&self) -> u8; fn channel_mut(&mut self) -> &mut u8; fn velocity(&self) -> u8; fn velocity_mut(&mut self) -> &mut u8; // Provided methods fn set_key(&mut self, key: u8) { ... } fn set_channel(&mut self, channel: u8) { ... } fn set_velocity(&mut self, velocity: u8) { ... } fn end(&self) -> T { ... } fn move_start(&mut self, start: T) { ... } fn set_end(&mut self, end: T) { ... } fn set_start(&mut self, start: T) { ... } fn set_len(&mut self, len: T) { ... }
}

Required Methods§

Source

fn start(&self) -> T

Source

fn start_mut(&mut self) -> &mut T

Source

fn len(&self) -> T

Source

fn len_mut(&mut self) -> &mut T

Source

fn key(&self) -> u8

Source

fn key_mut(&mut self) -> &mut u8

Source

fn channel(&self) -> u8

Source

fn channel_mut(&mut self) -> &mut u8

Source

fn velocity(&self) -> u8

Source

fn velocity_mut(&mut self) -> &mut u8

Provided Methods§

Source

fn set_key(&mut self, key: u8)

Source

fn set_channel(&mut self, channel: u8)

Source

fn set_velocity(&mut self, velocity: u8)

Source

fn end(&self) -> T

Source

fn move_start(&mut self, start: T)

Sets the note start and note length, keeping the end the same

Source

fn set_end(&mut self, end: T)

Sets the note length based on a new end, keeping the start the same

Source

fn set_start(&mut self, start: T)

Sets the note start, keeping the length the same

Source

fn set_len(&mut self, len: T)

Sets the note length, keeping the start the same

Implementors§

Source§

impl<T: MIDINum> MIDINote<T> for Note<T>