pub enum MusicErr {
InvalidInterval,
InvalidPitch(String),
ParseError(String),
}Variants§
Implementations§
Source§impl MusicErr
impl MusicErr
Sourcepub const fn is_invalid_interval(&self) -> bool
pub const fn is_invalid_interval(&self) -> bool
Returns true if the enum is MusicErr::InvalidInterval otherwise false
Sourcepub const fn is_invalid_pitch(&self) -> bool
pub const fn is_invalid_pitch(&self) -> bool
Returns true if the enum is MusicErr::InvalidPitch otherwise false
Sourcepub const fn is_parse_error(&self) -> bool
pub const fn is_parse_error(&self) -> bool
Returns true if the enum is MusicErr::ParseError otherwise false
Trait Implementations§
Source§impl<'de> Deserialize<'de> for MusicErr
impl<'de> Deserialize<'de> for MusicErr
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Error for MusicErr
impl Error for MusicErr
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Source§impl Ord for MusicErr
impl Ord for MusicErr
Source§impl PartialOrd for MusicErr
impl PartialOrd for MusicErr
Source§impl VariantNames for MusicErr
impl VariantNames for MusicErr
impl Eq for MusicErr
impl Send for MusicErr
impl StructuralPartialEq for MusicErr
impl Sync for MusicErr
Auto Trait Implementations§
impl Freeze for MusicErr
impl RefUnwindSafe for MusicErr
impl Unpin for MusicErr
impl UnwindSafe for MusicErr
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