97 lines
2.5 KiB
C#
97 lines
2.5 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Collections.ObjectModel;
|
|
using System.Text.Json.Serialization;
|
|
|
|
namespace Jellyfin.Plugin.SRFPlay.Api.Models;
|
|
|
|
/// <summary>
|
|
/// Represents a chapter (video/episode) in the SRF API response.
|
|
/// </summary>
|
|
public class Chapter
|
|
{
|
|
/// <summary>
|
|
/// Gets or sets the unique identifier.
|
|
/// </summary>
|
|
[JsonPropertyName("id")]
|
|
public string Id { get; set; } = string.Empty;
|
|
|
|
/// <summary>
|
|
/// Gets or sets the URN (Uniform Resource Name).
|
|
/// </summary>
|
|
[JsonPropertyName("urn")]
|
|
public string Urn { get; set; } = string.Empty;
|
|
|
|
/// <summary>
|
|
/// Gets or sets the title.
|
|
/// </summary>
|
|
[JsonPropertyName("title")]
|
|
public string Title { get; set; } = string.Empty;
|
|
|
|
/// <summary>
|
|
/// Gets or sets the lead/description.
|
|
/// </summary>
|
|
[JsonPropertyName("lead")]
|
|
public string? Lead { get; set; }
|
|
|
|
/// <summary>
|
|
/// Gets or sets the description.
|
|
/// </summary>
|
|
[JsonPropertyName("description")]
|
|
public string? Description { get; set; }
|
|
|
|
/// <summary>
|
|
/// Gets or sets the image URL.
|
|
/// </summary>
|
|
[JsonPropertyName("imageUrl")]
|
|
public string? ImageUrl { get; set; }
|
|
|
|
/// <summary>
|
|
/// Gets or sets the duration in milliseconds.
|
|
/// </summary>
|
|
[JsonPropertyName("duration")]
|
|
public long Duration { get; set; }
|
|
|
|
/// <summary>
|
|
/// Gets or sets the publication date.
|
|
/// </summary>
|
|
[JsonPropertyName("date")]
|
|
public DateTime? Date { get; set; }
|
|
|
|
/// <summary>
|
|
/// Gets or sets the valid from date.
|
|
/// </summary>
|
|
[JsonPropertyName("validFrom")]
|
|
public DateTime? ValidFrom { get; set; }
|
|
|
|
/// <summary>
|
|
/// Gets or sets the valid to date (expiration).
|
|
/// </summary>
|
|
[JsonPropertyName("validTo")]
|
|
public DateTime? ValidTo { get; set; }
|
|
|
|
/// <summary>
|
|
/// Gets or sets the list of available resources (streams).
|
|
/// </summary>
|
|
[JsonPropertyName("resourceList")]
|
|
public IReadOnlyList<Resource> ResourceList { get; set; } = new List<Resource>();
|
|
|
|
/// <summary>
|
|
/// Gets or sets the episode number.
|
|
/// </summary>
|
|
[JsonPropertyName("episodeNumber")]
|
|
public int? EpisodeNumber { get; set; }
|
|
|
|
/// <summary>
|
|
/// Gets or sets the season number.
|
|
/// </summary>
|
|
[JsonPropertyName("seasonNumber")]
|
|
public int? SeasonNumber { get; set; }
|
|
|
|
/// <summary>
|
|
/// Gets or sets the media type.
|
|
/// </summary>
|
|
[JsonPropertyName("mediaType")]
|
|
public string? MediaType { get; set; }
|
|
}
|