Table of Contents

Class LyricsLine

Namespace
Nyra.Entities
Assembly
Nyra.dll

One timed line of a lyrics result.

public sealed record LyricsLine : IEquatable<LyricsLine>
Inheritance
LyricsLine
Implements
Inherited Members

Remarks

Plain lyrics providers report theirs with a zero time and duration, this shape comes from NodeLink's load response.

Properties

Duration

Line duration, in milliseconds, 0 when the server does not know it.

[JsonPropertyName("duration")]
[JsonInclude]
[JsonConverter(typeof(RoundedInt64Converter))]
public long Duration { get; }

Property Value

long

Text

The text of the line.

[JsonPropertyName("text")]
[JsonInclude]
public string Text { get; }

Property Value

string

Time

Line start, in milliseconds.

[JsonPropertyName("time")]
[JsonInclude]
[JsonConverter(typeof(RoundedInt64Converter))]
public long Time { get; }

Property Value

long

Words

Per-word timings, when the provider supplies them.

[JsonPropertyName("words")]
[JsonInclude]
public JsonElement? Words { get; }

Property Value

JsonElement?

Methods

Equals(LyricsLine?)

Indicates whether the lines carry the same text, timing and raw words.

public bool Equals(LyricsLine? other)

Parameters

other LyricsLine

The line to compare with.

Returns

bool

Whether the members match, the raw words compared by content.

GetHashCode()

Returns a hash of the line's comparable members.

public override int GetHashCode()

Returns

int

The hash code.