Struct TrackFacts

Source
pub struct TrackFacts {
    pub recording: Option<String>,
    pub score: Option<u8>,
    pub title: Option<String>,
    pub artists: Vec<String>,
    pub album: Option<String>,
    pub works: Vec<WorkLink>,
    pub credits: Vec<CreditLink>,
    pub relationships_complete: bool,
    pub relationships_for: Option<String>,
}
Expand description

What a source says about one recorded performance.

A recording, not a release. AcoustID answers what is playing, and the same performance sits on the original album, the compilation and the deluxe reissue alike — so this identifies the track and says nothing about which pressing the file was ripped from, which the tags answer better.

AcoustID records arrive as Confidence::Matched: a fingerprint match is a strong guess and is wrong in ways that are easy to picture — two masterings of one recording fingerprint alike, and a very short or silent track matches a great deal. A later MusicBrainz identifier lookup is Confidence::Identified and can add relationship evidence to the same source record without turning it into a local tag.

Fields§

§recording: Option<String>

The MusicBrainz recording identifier the source named.

§score: Option<u8>

How sure the source said it was, as a percentage.

Rounded on the way in, from the fraction the service states. A stored float compares badly — two records that are the same answer would not be equal — and the difference between 98.12 % and 98 % is one nobody acts on. What a reader wants is a number to put beside a tag.

§title: Option<String>

The title, as the source spells it.

§artists: Vec<String>

The artists credited, in the order given.

§album: Option<String>

One release group the recording appears on, when the source named one.

§works: Vec<WorkLink>

Compositions MusicBrainz explicitly says this recording realizes.

Kept as source evidence rather than copied into the catalog: the same recording may be linked to several works (for example a medley), and a later reconciliation must be able to show exactly who made each claim.

§credits: Vec<CreditLink>

Credits attached directly to the recorded performance.

§relationships_complete: bool

Whether the recording relationship lookup completed, including when it returned no work or credit. This distinguishes “nothing there” from an older record that has never been asked for rich relationships.

§relationships_for: Option<String>

Recording selector whose completed lookup confirmed this identity.

A merged MusicBrainz ID can return a different canonical recording. Keeping the question separately lets a corrected local ID reopen the lookup without repeatedly requesting unchanged aliases. Refreshing the same canonical recording retains an earlier verified alias. Legacy receipts use their source identifier until the next successful lookup. A completed MusicBrainz snapshot with a consistent canonical recording can also establish this alias during identity checks, without overriding its confidence or explicit review.

Trait Implementations§

Source§

impl Clone for TrackFacts

Source§

fn clone(&self) -> TrackFacts

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for TrackFacts

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for TrackFacts

Source§

fn default() -> TrackFacts

Returns the “default value” for a type. Read more
Source§

impl PartialEq for TrackFacts

Source§

fn eq(&self, other: &TrackFacts) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Eq for TrackFacts

Source§

impl StructuralPartialEq for TrackFacts

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

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

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<S> FromSample<S> for S

§

fn from_sample_(s: S) -> S

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

§

impl<F, T> IntoSample<T> for F
where T: FromSample<F>,

§

fn into_sample(self) -> T

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
§

impl<T, U> ToSample<U> for T
where U: FromSample<T>,

§

fn to_sample_(self) -> U

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<S, T> Duplex<S> for T
where T: FromSample<S> + ToSample<S>,