pub enum HarmonicFunction {
Ambiguous,
Dominant,
LeadingTone,
Mediant,
Predominant,
Secondary,
Subdominant,
Submediant,
Supertonic,
Tonic,
}Expand description
Harmonic functions in tonal music
Variants§
Ambiguous
Dominant
LeadingTone
Mediant
Predominant
Secondary
Subdominant
Submediant
Supertonic
Tonic
Implementations§
Source§impl HarmonicFunction
impl HarmonicFunction
pub fn ambiguous() -> HarmonicFunction
pub fn dominant() -> HarmonicFunction
pub fn leading_tone() -> HarmonicFunction
pub fn mediant() -> HarmonicFunction
pub fn predominant() -> HarmonicFunction
pub fn secondary() -> HarmonicFunction
pub fn subdominant() -> HarmonicFunction
pub fn submediant() -> HarmonicFunction
pub fn supertonic() -> HarmonicFunction
pub fn tonic() -> HarmonicFunction
Source§impl HarmonicFunction
impl HarmonicFunction
Sourcepub const fn is_ambiguous(&self) -> bool
pub const fn is_ambiguous(&self) -> bool
Returns true if the enum is HarmonicFunction::Ambiguous otherwise false
Sourcepub const fn is_dominant(&self) -> bool
pub const fn is_dominant(&self) -> bool
Returns true if the enum is HarmonicFunction::Dominant otherwise false
Sourcepub const fn is_leading_tone(&self) -> bool
pub const fn is_leading_tone(&self) -> bool
Returns true if the enum is HarmonicFunction::LeadingTone otherwise false
Sourcepub const fn is_mediant(&self) -> bool
pub const fn is_mediant(&self) -> bool
Returns true if the enum is HarmonicFunction::Mediant otherwise false
Sourcepub const fn is_predominant(&self) -> bool
pub const fn is_predominant(&self) -> bool
Returns true if the enum is HarmonicFunction::Predominant otherwise false
Sourcepub const fn is_secondary(&self) -> bool
pub const fn is_secondary(&self) -> bool
Returns true if the enum is HarmonicFunction::Secondary otherwise false
Sourcepub const fn is_subdominant(&self) -> bool
pub const fn is_subdominant(&self) -> bool
Returns true if the enum is HarmonicFunction::Subdominant otherwise false
Sourcepub const fn is_submediant(&self) -> bool
pub const fn is_submediant(&self) -> bool
Returns true if the enum is HarmonicFunction::Submediant otherwise false
Sourcepub const fn is_supertonic(&self) -> bool
pub const fn is_supertonic(&self) -> bool
Returns true if the enum is HarmonicFunction::Supertonic otherwise false
Trait Implementations§
Source§impl AsRef<str> for HarmonicFunction
impl AsRef<str> for HarmonicFunction
Source§impl Clone for HarmonicFunction
impl Clone for HarmonicFunction
Source§fn clone(&self) -> HarmonicFunction
fn clone(&self) -> HarmonicFunction
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for HarmonicFunction
impl Debug for HarmonicFunction
Source§impl Display for HarmonicFunction
impl Display for HarmonicFunction
Source§impl FromStr for HarmonicFunction
impl FromStr for HarmonicFunction
Source§type Err = ParseError
type Err = ParseError
The associated error which can be returned from parsing.
Source§fn from_str(
s: &str,
) -> Result<HarmonicFunction, <HarmonicFunction as FromStr>::Err>
fn from_str( s: &str, ) -> Result<HarmonicFunction, <HarmonicFunction as FromStr>::Err>
Parses a string
s to return a value of this type. Read moreSource§impl Hash for HarmonicFunction
impl Hash for HarmonicFunction
Source§impl IntoEnumIterator for HarmonicFunction
impl IntoEnumIterator for HarmonicFunction
type Iterator = HarmonicFunctionIter
fn iter() -> HarmonicFunctionIter ⓘ
Source§impl Ord for HarmonicFunction
impl Ord for HarmonicFunction
Source§fn cmp(&self, other: &HarmonicFunction) -> Ordering
fn cmp(&self, other: &HarmonicFunction) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for HarmonicFunction
impl PartialEq for HarmonicFunction
Source§impl PartialOrd for HarmonicFunction
impl PartialOrd for HarmonicFunction
Source§impl TryFrom<&str> for HarmonicFunction
impl TryFrom<&str> for HarmonicFunction
Source§type Error = ParseError
type Error = ParseError
The type returned in the event of a conversion error.
Source§fn try_from(
s: &str,
) -> Result<HarmonicFunction, <HarmonicFunction as TryFrom<&str>>::Error>
fn try_from( s: &str, ) -> Result<HarmonicFunction, <HarmonicFunction as TryFrom<&str>>::Error>
Performs the conversion.
Source§impl VariantArray for HarmonicFunction
impl VariantArray for HarmonicFunction
const VARIANTS: &'static [HarmonicFunction]
Source§impl VariantNames for HarmonicFunction
impl VariantNames for HarmonicFunction
impl Copy for HarmonicFunction
impl Eq for HarmonicFunction
impl StructuralPartialEq for HarmonicFunction
Auto Trait Implementations§
impl Freeze for HarmonicFunction
impl RefUnwindSafe for HarmonicFunction
impl Send for HarmonicFunction
impl Sync for HarmonicFunction
impl Unpin for HarmonicFunction
impl UnwindSafe for HarmonicFunction
Blanket Implementations§
Source§impl<T> AsWeight<T> for Twhere
T: Clone + IntoWeight<T>,
impl<T> AsWeight<T> for Twhere
T: Clone + IntoWeight<T>,
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> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
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.Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more