repo creation with initial code after cloning public repo

This commit is contained in:
2026-02-19 07:36:25 -05:00
commit 460884fea3
2860 changed files with 650825 additions and 0 deletions
@@ -0,0 +1,29 @@
using Jellyfin.Data.Enums;
#nullable disable
namespace MediaBrowser.Model.Session
{
/// <summary>
/// Class BrowseRequest.
/// </summary>
public class BrowseRequest
{
/// <summary>
/// Gets or sets the item type.
/// </summary>
/// <value>The type of the item.</value>
public BaseItemKind ItemType { get; set; }
/// <summary>
/// Gets or sets the item id.
/// </summary>
/// <value>The item id.</value>
public string ItemId { get; set; }
/// <summary>
/// Gets or sets the name of the item.
/// </summary>
/// <value>The name of the item.</value>
public string ItemName { get; set; }
}
}
@@ -0,0 +1,34 @@
#nullable disable
#pragma warning disable CS1591
using System;
using System.Collections.Generic;
using Jellyfin.Data.Enums;
using MediaBrowser.Model.Dlna;
namespace MediaBrowser.Model.Session
{
public class ClientCapabilities
{
public ClientCapabilities()
{
PlayableMediaTypes = Array.Empty<MediaType>();
SupportedCommands = Array.Empty<GeneralCommandType>();
SupportsPersistentIdentifier = true;
}
public IReadOnlyList<MediaType> PlayableMediaTypes { get; set; }
public IReadOnlyList<GeneralCommandType> SupportedCommands { get; set; }
public bool SupportsMediaControl { get; set; }
public bool SupportsPersistentIdentifier { get; set; }
public DeviceProfile DeviceProfile { get; set; }
public string AppStoreUrl { get; set; }
public string IconUrl { get; set; }
}
}
@@ -0,0 +1,27 @@
#pragma warning disable CS1591
using System;
using System.Collections.Generic;
using System.Text.Json.Serialization;
namespace MediaBrowser.Model.Session;
public class GeneralCommand
{
public GeneralCommand()
: this(new Dictionary<string, string>())
{
}
[JsonConstructor]
public GeneralCommand(Dictionary<string, string>? arguments)
{
Arguments = arguments ?? new Dictionary<string, string>();
}
public GeneralCommandType Name { get; set; }
public Guid ControllingUserId { get; set; }
public Dictionary<string, string> Arguments { get; }
}
@@ -0,0 +1,54 @@
#pragma warning disable CS1591
namespace MediaBrowser.Model.Session
{
/// <summary>
/// This exists simply to identify a set of known commands.
/// </summary>
public enum GeneralCommandType
{
MoveUp = 0,
MoveDown = 1,
MoveLeft = 2,
MoveRight = 3,
PageUp = 4,
PageDown = 5,
PreviousLetter = 6,
NextLetter = 7,
ToggleOsd = 8,
ToggleContextMenu = 9,
Select = 10,
Back = 11,
TakeScreenshot = 12,
SendKey = 13,
SendString = 14,
GoHome = 15,
GoToSettings = 16,
VolumeUp = 17,
VolumeDown = 18,
Mute = 19,
Unmute = 20,
ToggleMute = 21,
SetVolume = 22,
SetAudioStreamIndex = 23,
SetSubtitleStreamIndex = 24,
ToggleFullscreen = 25,
DisplayContent = 26,
GoToSearch = 27,
DisplayMessage = 28,
SetRepeatMode = 29,
ChannelUp = 30,
ChannelDown = 31,
Guide = 32,
ToggleStats = 33,
PlayMediaSource = 34,
PlayTrailers = 35,
SetShuffleQueue = 36,
PlayState = 37,
PlayNext = 38,
ToggleOsdMenu = 39,
Play = 40,
SetMaxStreamingBitrate = 41,
SetPlaybackOrder = 42
}
}
@@ -0,0 +1,17 @@
#nullable disable
#pragma warning disable CS1591
using System.ComponentModel.DataAnnotations;
namespace MediaBrowser.Model.Session
{
public class MessageCommand
{
public string Header { get; set; }
[Required(AllowEmptyStrings = false)]
public string Text { get; set; }
public long? TimeoutMs { get; set; }
}
}
+33
View File
@@ -0,0 +1,33 @@
namespace MediaBrowser.Model.Session
{
/// <summary>
/// Enum PlayCommand.
/// </summary>
public enum PlayCommand
{
/// <summary>
/// The play now.
/// </summary>
PlayNow = 0,
/// <summary>
/// The play next.
/// </summary>
PlayNext = 1,
/// <summary>
/// The play last.
/// </summary>
PlayLast = 2,
/// <summary>
/// The play instant mix.
/// </summary>
PlayInstantMix = 3,
/// <summary>
/// The play shuffle.
/// </summary>
PlayShuffle = 4
}
}
+11
View File
@@ -0,0 +1,11 @@
#pragma warning disable CS1591
namespace MediaBrowser.Model.Session
{
public enum PlayMethod
{
Transcode = 0,
DirectStream = 1,
DirectPlay = 2
}
}
+45
View File
@@ -0,0 +1,45 @@
#nullable disable
#pragma warning disable CS1591
using System;
namespace MediaBrowser.Model.Session
{
/// <summary>
/// Class PlayRequest.
/// </summary>
public class PlayRequest
{
/// <summary>
/// Gets or sets the item ids.
/// </summary>
/// <value>The item ids.</value>
public Guid[] ItemIds { get; set; }
/// <summary>
/// Gets or sets the start position ticks that the first item should be played at.
/// </summary>
/// <value>The start position ticks.</value>
public long? StartPositionTicks { get; set; }
/// <summary>
/// Gets or sets the play command.
/// </summary>
/// <value>The play command.</value>
public PlayCommand PlayCommand { get; set; }
/// <summary>
/// Gets or sets the controlling user identifier.
/// </summary>
/// <value>The controlling user identifier.</value>
public Guid ControllingUserId { get; set; }
public int? SubtitleStreamIndex { get; set; }
public int? AudioStreamIndex { get; set; }
public string MediaSourceId { get; set; }
public int? StartIndex { get; set; }
}
}
@@ -0,0 +1,18 @@
namespace MediaBrowser.Model.Session
{
/// <summary>
/// Enum PlaybackOrder.
/// </summary>
public enum PlaybackOrder
{
/// <summary>
/// Sorted playlist.
/// </summary>
Default = 0,
/// <summary>
/// Shuffled playlist.
/// </summary>
Shuffle = 1
}
}
@@ -0,0 +1,120 @@
#nullable disable
#pragma warning disable CS1591
using System;
using MediaBrowser.Model.Dto;
namespace MediaBrowser.Model.Session
{
/// <summary>
/// Class PlaybackProgressInfo.
/// </summary>
public class PlaybackProgressInfo
{
/// <summary>
/// Gets or sets a value indicating whether this instance can seek.
/// </summary>
/// <value><c>true</c> if this instance can seek; otherwise, <c>false</c>.</value>
public bool CanSeek { get; set; }
/// <summary>
/// Gets or sets the item.
/// </summary>
/// <value>The item.</value>
public BaseItemDto Item { get; set; }
/// <summary>
/// Gets or sets the item identifier.
/// </summary>
/// <value>The item identifier.</value>
public Guid ItemId { get; set; }
/// <summary>
/// Gets or sets the session id.
/// </summary>
/// <value>The session id.</value>
public string SessionId { get; set; }
/// <summary>
/// Gets or sets the media version identifier.
/// </summary>
/// <value>The media version identifier.</value>
public string MediaSourceId { get; set; }
/// <summary>
/// Gets or sets the index of the audio stream.
/// </summary>
/// <value>The index of the audio stream.</value>
public int? AudioStreamIndex { get; set; }
/// <summary>
/// Gets or sets the index of the subtitle stream.
/// </summary>
/// <value>The index of the subtitle stream.</value>
public int? SubtitleStreamIndex { get; set; }
/// <summary>
/// Gets or sets a value indicating whether this instance is paused.
/// </summary>
/// <value><c>true</c> if this instance is paused; otherwise, <c>false</c>.</value>
public bool IsPaused { get; set; }
/// <summary>
/// Gets or sets a value indicating whether this instance is muted.
/// </summary>
/// <value><c>true</c> if this instance is muted; otherwise, <c>false</c>.</value>
public bool IsMuted { get; set; }
/// <summary>
/// Gets or sets the position ticks.
/// </summary>
/// <value>The position ticks.</value>
public long? PositionTicks { get; set; }
public long? PlaybackStartTimeTicks { get; set; }
/// <summary>
/// Gets or sets the volume level.
/// </summary>
/// <value>The volume level.</value>
public int? VolumeLevel { get; set; }
public int? Brightness { get; set; }
public string AspectRatio { get; set; }
/// <summary>
/// Gets or sets the play method.
/// </summary>
/// <value>The play method.</value>
public PlayMethod PlayMethod { get; set; }
/// <summary>
/// Gets or sets the live stream identifier.
/// </summary>
/// <value>The live stream identifier.</value>
public string LiveStreamId { get; set; }
/// <summary>
/// Gets or sets the play session identifier.
/// </summary>
/// <value>The play session identifier.</value>
public string PlaySessionId { get; set; }
/// <summary>
/// Gets or sets the repeat mode.
/// </summary>
/// <value>The repeat mode.</value>
public RepeatMode RepeatMode { get; set; }
/// <summary>
/// Gets or sets the playback order.
/// </summary>
/// <value>The playback order.</value>
public PlaybackOrder PlaybackOrder { get; set; }
public QueueItem[] NowPlayingQueue { get; set; }
public string PlaylistItemId { get; set; }
}
}
@@ -0,0 +1,9 @@
namespace MediaBrowser.Model.Session
{
/// <summary>
/// Class PlaybackStartInfo.
/// </summary>
public class PlaybackStartInfo : PlaybackProgressInfo
{
}
}
@@ -0,0 +1,68 @@
#nullable disable
#pragma warning disable CS1591
using System;
using MediaBrowser.Model.Dto;
namespace MediaBrowser.Model.Session
{
/// <summary>
/// Class PlaybackStopInfo.
/// </summary>
public class PlaybackStopInfo
{
/// <summary>
/// Gets or sets the item.
/// </summary>
/// <value>The item.</value>
public BaseItemDto Item { get; set; }
/// <summary>
/// Gets or sets the item identifier.
/// </summary>
/// <value>The item identifier.</value>
public Guid ItemId { get; set; }
/// <summary>
/// Gets or sets the session id.
/// </summary>
/// <value>The session id.</value>
public string SessionId { get; set; }
/// <summary>
/// Gets or sets the media version identifier.
/// </summary>
/// <value>The media version identifier.</value>
public string MediaSourceId { get; set; }
/// <summary>
/// Gets or sets the position ticks.
/// </summary>
/// <value>The position ticks.</value>
public long? PositionTicks { get; set; }
/// <summary>
/// Gets or sets the live stream identifier.
/// </summary>
/// <value>The live stream identifier.</value>
public string LiveStreamId { get; set; }
/// <summary>
/// Gets or sets the play session identifier.
/// </summary>
/// <value>The play session identifier.</value>
public string PlaySessionId { get; set; }
/// <summary>
/// Gets or sets a value indicating whether this <see cref="PlaybackStopInfo"/> is failed.
/// </summary>
/// <value><c>true</c> if failed; otherwise, <c>false</c>.</value>
public bool Failed { get; set; }
public string NextMediaType { get; set; }
public string PlaylistItemId { get; set; }
public QueueItem[] NowPlayingQueue { get; set; }
}
}
@@ -0,0 +1,80 @@
#nullable disable
#pragma warning disable CS1591
namespace MediaBrowser.Model.Session
{
public class PlayerStateInfo
{
/// <summary>
/// Gets or sets the now playing position ticks.
/// </summary>
/// <value>The now playing position ticks.</value>
public long? PositionTicks { get; set; }
/// <summary>
/// Gets or sets a value indicating whether this instance can seek.
/// </summary>
/// <value><c>true</c> if this instance can seek; otherwise, <c>false</c>.</value>
public bool CanSeek { get; set; }
/// <summary>
/// Gets or sets a value indicating whether this instance is paused.
/// </summary>
/// <value><c>true</c> if this instance is paused; otherwise, <c>false</c>.</value>
public bool IsPaused { get; set; }
/// <summary>
/// Gets or sets a value indicating whether this instance is muted.
/// </summary>
/// <value><c>true</c> if this instance is muted; otherwise, <c>false</c>.</value>
public bool IsMuted { get; set; }
/// <summary>
/// Gets or sets the volume level.
/// </summary>
/// <value>The volume level.</value>
public int? VolumeLevel { get; set; }
/// <summary>
/// Gets or sets the index of the now playing audio stream.
/// </summary>
/// <value>The index of the now playing audio stream.</value>
public int? AudioStreamIndex { get; set; }
/// <summary>
/// Gets or sets the index of the now playing subtitle stream.
/// </summary>
/// <value>The index of the now playing subtitle stream.</value>
public int? SubtitleStreamIndex { get; set; }
/// <summary>
/// Gets or sets the now playing media version identifier.
/// </summary>
/// <value>The now playing media version identifier.</value>
public string MediaSourceId { get; set; }
/// <summary>
/// Gets or sets the play method.
/// </summary>
/// <value>The play method.</value>
public PlayMethod? PlayMethod { get; set; }
/// <summary>
/// Gets or sets the repeat mode.
/// </summary>
/// <value>The repeat mode.</value>
public RepeatMode RepeatMode { get; set; }
/// <summary>
/// Gets or sets the playback order.
/// </summary>
/// <value>The playback order.</value>
public PlaybackOrder PlaybackOrder { get; set; }
/// <summary>
/// Gets or sets the now playing live stream identifier.
/// </summary>
/// <value>The live stream identifier.</value>
public string LiveStreamId { get; set; }
}
}
@@ -0,0 +1,53 @@
namespace MediaBrowser.Model.Session
{
/// <summary>
/// Enum PlaystateCommand.
/// </summary>
public enum PlaystateCommand
{
/// <summary>
/// The stop.
/// </summary>
Stop,
/// <summary>
/// The pause.
/// </summary>
Pause,
/// <summary>
/// The unpause.
/// </summary>
Unpause,
/// <summary>
/// The next track.
/// </summary>
NextTrack,
/// <summary>
/// The previous track.
/// </summary>
PreviousTrack,
/// <summary>
/// The seek.
/// </summary>
Seek,
/// <summary>
/// The rewind.
/// </summary>
Rewind,
/// <summary>
/// The fast forward.
/// </summary>
FastForward,
/// <summary>
/// The play pause.
/// </summary>
PlayPause
}
}
@@ -0,0 +1,17 @@
#pragma warning disable CS1591
namespace MediaBrowser.Model.Session
{
public class PlaystateRequest
{
public PlaystateCommand Command { get; set; }
public long? SeekPositionTicks { get; set; }
/// <summary>
/// Gets or sets the controlling user identifier.
/// </summary>
/// <value>The controlling user identifier.</value>
public string? ControllingUserId { get; set; }
}
}
+13
View File
@@ -0,0 +1,13 @@
#nullable disable
#pragma warning disable CS1591
using System;
namespace MediaBrowser.Model.Session;
public record QueueItem
{
public Guid Id { get; set; }
public string PlaylistItemId { get; set; }
}
+11
View File
@@ -0,0 +1,11 @@
#pragma warning disable CS1591
namespace MediaBrowser.Model.Session
{
public enum RepeatMode
{
RepeatNone = 0,
RepeatAll = 1,
RepeatOne = 2
}
}
@@ -0,0 +1,50 @@
#pragma warning disable CS1591
namespace MediaBrowser.Model.Session
{
/// <summary>
/// The different kinds of messages that are used in the WebSocket api.
/// </summary>
public enum SessionMessageType
{
// Server -> Client
ForceKeepAlive,
GeneralCommand,
UserDataChanged,
Sessions,
Play,
SyncPlayCommand,
SyncPlayGroupUpdate,
Playstate,
RestartRequired,
ServerShuttingDown,
ServerRestarting,
LibraryChanged,
UserDeleted,
UserUpdated,
SeriesTimerCreated,
TimerCreated,
SeriesTimerCancelled,
TimerCancelled,
RefreshProgress,
ScheduledTaskEnded,
PackageInstallationCancelled,
PackageInstallationFailed,
PackageInstallationCompleted,
PackageInstalling,
PackageUninstalled,
ActivityLogEntry,
ScheduledTasksInfo,
// Client -> Server
ActivityLogEntryStart,
ActivityLogEntryStop,
SessionsStart,
SessionsStop,
ScheduledTasksInfoStart,
ScheduledTasksInfoStop,
// Shared
KeepAlive,
}
}
@@ -0,0 +1,23 @@
#nullable disable
using System;
namespace MediaBrowser.Model.Session
{
/// <summary>
/// Class SessionUserInfo.
/// </summary>
public class SessionUserInfo
{
/// <summary>
/// Gets or sets the user identifier.
/// </summary>
/// <value>The user identifier.</value>
public Guid UserId { get; set; }
/// <summary>
/// Gets or sets the name of the user.
/// </summary>
/// <value>The name of the user.</value>
public string UserName { get; set; }
}
}
@@ -0,0 +1,47 @@
#pragma warning disable CS1591
using System;
namespace MediaBrowser.Model.Session
{
[Flags]
public enum TranscodeReason
{
// Primary
ContainerNotSupported = 1 << 0,
VideoCodecNotSupported = 1 << 1,
AudioCodecNotSupported = 1 << 2,
SubtitleCodecNotSupported = 1 << 3,
AudioIsExternal = 1 << 4,
SecondaryAudioNotSupported = 1 << 5,
StreamCountExceedsLimit = 1 << 26,
// Video Constraints
VideoProfileNotSupported = 1 << 6,
VideoRangeTypeNotSupported = 1 << 24,
VideoCodecTagNotSupported = 1 << 25,
VideoLevelNotSupported = 1 << 7,
VideoResolutionNotSupported = 1 << 8,
VideoBitDepthNotSupported = 1 << 9,
VideoFramerateNotSupported = 1 << 10,
RefFramesNotSupported = 1 << 11,
AnamorphicVideoNotSupported = 1 << 12,
InterlacedVideoNotSupported = 1 << 13,
// Audio Constraints
AudioChannelsNotSupported = 1 << 14,
AudioProfileNotSupported = 1 << 15,
AudioSampleRateNotSupported = 1 << 16,
AudioBitDepthNotSupported = 1 << 17,
// Bitrate Constraints
ContainerBitrateExceedsLimit = 1 << 18,
VideoBitrateNotSupported = 1 << 19,
AudioBitrateNotSupported = 1 << 20,
// Errors
UnknownVideoStreamInfo = 1 << 21,
UnknownAudioStreamInfo = 1 << 22,
DirectPlayError = 1 << 23,
}
}
@@ -0,0 +1,76 @@
#nullable disable
using MediaBrowser.Model.Entities;
namespace MediaBrowser.Model.Session;
/// <summary>
/// Class holding information on a running transcode.
/// </summary>
public class TranscodingInfo
{
/// <summary>
/// Gets or sets the thread count used for encoding.
/// </summary>
public string AudioCodec { get; set; }
/// <summary>
/// Gets or sets the thread count used for encoding.
/// </summary>
public string VideoCodec { get; set; }
/// <summary>
/// Gets or sets the thread count used for encoding.
/// </summary>
public string Container { get; set; }
/// <summary>
/// Gets or sets a value indicating whether the video is passed through.
/// </summary>
public bool IsVideoDirect { get; set; }
/// <summary>
/// Gets or sets a value indicating whether the audio is passed through.
/// </summary>
public bool IsAudioDirect { get; set; }
/// <summary>
/// Gets or sets the bitrate.
/// </summary>
public int? Bitrate { get; set; }
/// <summary>
/// Gets or sets the framerate.
/// </summary>
public float? Framerate { get; set; }
/// <summary>
/// Gets or sets the completion percentage.
/// </summary>
public double? CompletionPercentage { get; set; }
/// <summary>
/// Gets or sets the video width.
/// </summary>
public int? Width { get; set; }
/// <summary>
/// Gets or sets the video height.
/// </summary>
public int? Height { get; set; }
/// <summary>
/// Gets or sets the audio channels.
/// </summary>
public int? AudioChannels { get; set; }
/// <summary>
/// Gets or sets the hardware acceleration type.
/// </summary>
public HardwareAccelerationType? HardwareAccelerationType { get; set; }
/// <summary>
/// Gets or sets the transcode reasons.
/// </summary>
public TranscodeReason TranscodeReasons { get; set; }
}
@@ -0,0 +1,23 @@
using System;
using MediaBrowser.Model.Dto;
namespace MediaBrowser.Model.Session
{
/// <summary>
/// Class UserDataChangeInfo.
/// </summary>
public class UserDataChangeInfo
{
/// <summary>
/// Gets or sets the user id.
/// </summary>
/// <value>The user id.</value>
public Guid UserId { get; set; }
/// <summary>
/// Gets or sets the user data list.
/// </summary>
/// <value>The user data list.</value>
public required UserItemDataDto[] UserDataList { get; set; }
}
}