mirror of
https://github.com/BinaryAlley/Nemera.git
synced 2026-12-03 14:11:10 +00:00
Adds playlist management and playback
This commit is contained in:
1 parent
009a0c8156
commit
9889c86c76
296 files changed
+18830
-367
No files matched your search
@@ -0,0 +1,16 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
#endregion
|
||||
|
||||
namespace Lumina.Contracts.Requests.Playlists;
|
||||
|
||||
/// <summary>
|
||||
/// Represents a request for adding several tracks to a playlist of the current user, in order.
|
||||
/// </summary>
|
||||
/// <param name="TrackIds">The Ids of the tracks to add, in the order they must take. Required.</param>
|
||||
[DebuggerDisplay("TrackCount: {TrackIds.Count}")]
|
||||
public record AddPlaylistEntriesRequest(
|
||||
List<Guid>? TrackIds
|
||||
);
|
||||
@@ -0,0 +1,15 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
#endregion
|
||||
|
||||
namespace Lumina.Contracts.Requests.Playlists;
|
||||
|
||||
/// <summary>
|
||||
/// Represents a request for adding a track to a playlist of the current user.
|
||||
/// </summary>
|
||||
/// <param name="TrackId">The Id of the track to add. Required.</param>
|
||||
[DebuggerDisplay("TrackId: {TrackId}")]
|
||||
public record AddPlaylistEntryRequest(
|
||||
Guid? TrackId
|
||||
);
|
||||
@@ -0,0 +1,19 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
#endregion
|
||||
|
||||
namespace Lumina.Contracts.Requests.Playlists;
|
||||
|
||||
/// <summary>
|
||||
/// Represents a request to add every track of a music library, an artist or an album to a playlist, resolved on the server.
|
||||
/// </summary>
|
||||
/// <param name="LibraryId">The Id of the music library the scope belongs to. Required.</param>
|
||||
/// <param name="ArtistId">The Id of the artist the scope is limited to. Optional.</param>
|
||||
/// <param name="AlbumId">The Id of the album the scope is limited to. Optional.</param>
|
||||
[DebuggerDisplay("LibraryId: {LibraryId}; ArtistId: {ArtistId}; AlbumId: {AlbumId}")]
|
||||
public record AddPlaylistScopeEntriesRequest(
|
||||
Guid LibraryId,
|
||||
Guid? ArtistId = null,
|
||||
Guid? AlbumId = null
|
||||
);
|
||||
@@ -0,0 +1,19 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.Playlists;
|
||||
using System.Diagnostics;
|
||||
#endregion
|
||||
|
||||
namespace Lumina.Contracts.Requests.Playlists;
|
||||
|
||||
/// <summary>
|
||||
/// Represents a request for creating a playlist of the current user.
|
||||
/// </summary>
|
||||
/// <param name="Name">The name of the playlist. Required.</param>
|
||||
/// <param name="Description">The description of the playlist. Optional.</param>
|
||||
/// <param name="Type">The kind of media the playlist holds. Required.</param>
|
||||
[DebuggerDisplay("Name: {Name}")]
|
||||
public record CreatePlaylistRequest(
|
||||
string? Name,
|
||||
string? Description,
|
||||
PlaylistType? Type
|
||||
);
|
||||
@@ -0,0 +1,16 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using System.Diagnostics;
|
||||
#endregion
|
||||
|
||||
namespace Lumina.Contracts.Requests.Playlists;
|
||||
|
||||
/// <summary>
|
||||
/// Represents a request for getting a window of the entries of a playlist of the current user.
|
||||
/// </summary>
|
||||
/// <param name="Offset">The zero based position of the first entry to return. Optional; defaults to 0.</param>
|
||||
/// <param name="Limit">The maximum number of entries to return, from 1 to 1000. Optional; defaults to 200.</param>
|
||||
[DebuggerDisplay("Offset: {Offset}; Limit: {Limit}")]
|
||||
public record GetPlaylistRequest(
|
||||
int? Offset,
|
||||
int? Limit
|
||||
);
|
||||
@@ -0,0 +1,14 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using System.Diagnostics;
|
||||
#endregion
|
||||
|
||||
namespace Lumina.Contracts.Requests.Playlists;
|
||||
|
||||
/// <summary>
|
||||
/// Represents a request for moving one entry of a playlist of the current user to a new position.
|
||||
/// </summary>
|
||||
/// <param name="TargetPosition">The new zero based position of the entry. Required.</param>
|
||||
[DebuggerDisplay("TargetPosition: {TargetPosition}")]
|
||||
public record MovePlaylistEntryRequest(
|
||||
int? TargetPosition
|
||||
);
|
||||
@@ -0,0 +1,16 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using System.Diagnostics;
|
||||
#endregion
|
||||
|
||||
namespace Lumina.Contracts.Requests.Playlists;
|
||||
|
||||
/// <summary>
|
||||
/// Represents a request for updating the details of a playlist of the current user.
|
||||
/// </summary>
|
||||
/// <param name="Name">The name of the playlist. Required.</param>
|
||||
/// <param name="Description">The description of the playlist. Optional.</param>
|
||||
[DebuggerDisplay("Name: {Name}")]
|
||||
public record UpdatePlaylistRequest(
|
||||
string? Name,
|
||||
string? Description
|
||||
);
|
||||
Reference in new issue
Block a user