feat(api): add schedule item duration estimates

refs #111
This commit is contained in:
2026-07-03 23:41:57 +02:00
parent d0652d4adb
commit 4b4e2b2f82
7 changed files with 304 additions and 27 deletions
@@ -46,7 +46,7 @@ public abstract record ProgramScheduleItemViewModel(
{
/// <summary>
/// A rough estimate, in wall-clock time, of how long a single pass of this schedule item will play,
/// derived from the aggregated runtimes (<c>MediaVersion.Duration</c>) of the referenced content.
/// derived from the aggregated playout runtimes of the referenced content.
/// <para>
/// Semantics by <see cref="PlayoutMode" />:
/// <list type="bullet">
@@ -57,15 +57,12 @@ public abstract record ProgramScheduleItemViewModel(
/// <see cref="MultipleMode.CollectionSize" />.
/// </item>
/// <item><b>Flood</b> — always <c>null</c>: a flood item fills the remaining time and is unbounded.</item>
/// <item>
/// <b>Duration</b> — always <c>null</c>: its runtime is the explicit
/// <c>playoutDuration</c> setting already present on the item, so it is not re-derived here.
/// </item>
/// <item><b>Duration</b> — the explicit <c>playoutDuration</c> setting on the item.</item>
/// </list>
/// </para>
/// <para>
/// <c>null</c> whenever a bounded estimate cannot be produced — an unbounded mode (Flood/Duration),
/// a referenced collection with no items that have a known non-zero duration, a Multiple mode other
/// <c>null</c> whenever a bounded estimate cannot be produced — an unbounded mode (Flood),
/// a referenced collection with no items that have a known positive duration, a Multiple mode other
/// than Count/CollectionSize, or a collection type other than <see cref="CollectionType.Collection" />
/// (smart/multi/playlist/search/rerun/show/season/artist references are not aggregated in this pass).
/// Callers should treat a <c>null</c> as "unknown", never as zero.