ClosestPitch class

An abstraction of the closest representation of a Frequency as a Pitch.


See also:

Annotations
  • @immutable

Constructors

ClosestPitch(Pitch pitch, {Cent cents = const Cent(0)})
Creates a new ClosestPitch from pitch and cents.
const
ClosestPitch.parse(String source)
Parse source as a ClosestPitch and return its value.
factory

Properties

cents Cent
The difference in cents.
final
hashCode int
The hash code for this object.
no setteroverride
pitch Pitch
The Pitch closest to the original Frequency.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

frequency({Frequency referenceFrequency = const Frequency(440), TuningSystem tuningSystem = const EqualTemperament.edo12()}) Frequency
The Frequency of this ClosestPitch from referenceFrequency and tuningSystem.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
The string representation of this ClosestPitch record.
override

Operators

operator ==(Object other) bool
The equality operator.
override