mirror of
https://github.com/BinaryAlley/Nemera.git
synced 2026-12-03 04:11:10 +00:00
Refactors the book, artist, and album slices across the stack
This commit is contained in:
1 parent
8aaf9fe64e
commit
ea6eb9f796
439 files changed
+28235
-3156
No files matched your search
+40
@@ -0,0 +1,40 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using Lumina.Contracts.DTO.Common;
|
||||
using Lumina.Contracts.DTO.MediaContributors;
|
||||
using Lumina.Contracts.DTO.MediaLibrary.AudioLibrary;
|
||||
using Lumina.Contracts.DTO.MediaLibrary.AudioLibrary.MusicLibrary;
|
||||
using Lumina.Contracts.Requests.MediaLibrary.AudioLibrary.MusicLibrary.Tracks;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.AudioLibrary;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
#endregion
|
||||
|
||||
namespace Lumina.Contracts.Requests.MediaLibrary.AudioLibrary.MusicLibrary.Albums;
|
||||
|
||||
/// <summary>
|
||||
/// Represents a request to add an album to an artist, together with the tracks of the album.
|
||||
/// </summary>
|
||||
/// <param name="Metadata">The album metadata of the album. Required.</param>
|
||||
/// <param name="MediaFormat">The physical or digital medium of the album. Optional.</param>
|
||||
/// <param name="Barcode">The barcode of the album. Optional.</param>
|
||||
/// <param name="CatalogNumber">The catalog number of the album. Optional.</param>
|
||||
/// <param name="MusicBrainzReleaseId">The MusicBrainz identifier of the release. Optional.</param>
|
||||
/// <param name="MusicBrainzReleaseGroupId">The MusicBrainz identifier of the release group. Optional.</param>
|
||||
/// <param name="MusicBrainzReleaseArtistId">The MusicBrainz identifier of the release artist. Optional.</param>
|
||||
/// <param name="Contributors">The list of media contributors that performed on the album. Required.</param>
|
||||
/// <param name="Ratings">The list of ratings for this album. Required.</param>
|
||||
/// <param name="Tracks">The list of tracks of the album. Required.</param>
|
||||
[DebuggerDisplay("Title: {Metadata.Title}")]
|
||||
public record AddAlbumRequest(
|
||||
AlbumMetadataDto? Metadata,
|
||||
MusicMediaFormat? MediaFormat,
|
||||
string? Barcode,
|
||||
string? CatalogNumber,
|
||||
Guid? MusicBrainzReleaseId,
|
||||
Guid? MusicBrainzReleaseGroupId,
|
||||
Guid? MusicBrainzReleaseArtistId,
|
||||
List<MediaContributorReferenceDto>? Contributors,
|
||||
List<AudioRatingDto>? Ratings,
|
||||
List<AddTrackRequest>? Tracks
|
||||
);
|
||||
+17
@@ -0,0 +1,17 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
#endregion
|
||||
|
||||
namespace Lumina.Contracts.Requests.MediaLibrary.AudioLibrary.MusicLibrary.Albums;
|
||||
|
||||
/// <summary>
|
||||
/// Represents a request to delete an album by the specified Id.
|
||||
/// </summary>
|
||||
/// <param name="ArtistId">The unique identifier of the artist the album belongs to, taken from the route.</param>
|
||||
/// <param name="AlbumId">The unique identifier of the album to delete.</param>
|
||||
[DebuggerDisplay("AlbumId: {AlbumId}")]
|
||||
public record DeleteAlbumRequest(
|
||||
Guid ArtistId,
|
||||
Guid AlbumId
|
||||
);
|
||||
+17
@@ -0,0 +1,17 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
#endregion
|
||||
|
||||
namespace Lumina.Contracts.Requests.MediaLibrary.AudioLibrary.MusicLibrary.Albums;
|
||||
|
||||
/// <summary>
|
||||
/// Represents a request to get an album by the specified Id.
|
||||
/// </summary>
|
||||
/// <param name="ArtistId">The unique identifier of the artist the album belongs to, taken from the route.</param>
|
||||
/// <param name="AlbumId">The unique identifier of the album to retrieve.</param>
|
||||
[DebuggerDisplay("AlbumId: {AlbumId}")]
|
||||
public record GetAlbumRequest(
|
||||
Guid ArtistId,
|
||||
Guid AlbumId
|
||||
);
|
||||
+21
@@ -0,0 +1,21 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
#endregion
|
||||
|
||||
namespace Lumina.Contracts.Requests.MediaLibrary.AudioLibrary.MusicLibrary.Albums;
|
||||
|
||||
/// <summary>
|
||||
/// Represents a request to get the lightweight read models of the tracks of an album.
|
||||
/// </summary>
|
||||
/// <param name="ArtistId">The unique identifier of the artist the album belongs to, taken from the route.</param>
|
||||
/// <param name="AlbumId">The unique identifier of the album whose tracks are retrieved.</param>
|
||||
/// <param name="CurrentPage">The page of results to retrieve. Optional.</param>
|
||||
/// <param name="PerPage">The maximum number of tracks to retrieve per page. Optional.</param>
|
||||
[DebuggerDisplay("AlbumId: {AlbumId}")]
|
||||
public record GetAlbumTracksLiteRequest(
|
||||
Guid ArtistId,
|
||||
Guid AlbumId,
|
||||
int? CurrentPage,
|
||||
int? PerPage
|
||||
);
|
||||
+17
@@ -0,0 +1,17 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
#endregion
|
||||
|
||||
namespace Lumina.Contracts.Requests.MediaLibrary.AudioLibrary.MusicLibrary.Albums;
|
||||
|
||||
/// <summary>
|
||||
/// Represents a request to get the tracks of an album.
|
||||
/// </summary>
|
||||
/// <param name="ArtistId">The unique identifier of the artist the album belongs to, taken from the route.</param>
|
||||
/// <param name="AlbumId">The unique identifier of the album whose tracks are retrieved.</param>
|
||||
[DebuggerDisplay("AlbumId: {AlbumId}")]
|
||||
public record GetAlbumTracksRequest(
|
||||
Guid ArtistId,
|
||||
Guid AlbumId
|
||||
);
|
||||
+37
@@ -0,0 +1,37 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using Lumina.Contracts.DTO.Common;
|
||||
using Lumina.Contracts.DTO.MediaContributors;
|
||||
using Lumina.Contracts.DTO.MediaLibrary.AudioLibrary;
|
||||
using Lumina.Contracts.DTO.MediaLibrary.AudioLibrary.MusicLibrary;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.AudioLibrary;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
#endregion
|
||||
|
||||
namespace Lumina.Contracts.Requests.MediaLibrary.AudioLibrary.MusicLibrary.Albums;
|
||||
|
||||
/// <summary>
|
||||
/// Represents a request to update an existing album.
|
||||
/// </summary>
|
||||
/// <param name="Metadata">The album metadata of the album. Required.</param>
|
||||
/// <param name="MediaFormat">The physical or digital medium of the album. Optional.</param>
|
||||
/// <param name="Barcode">The barcode of the album. Optional.</param>
|
||||
/// <param name="CatalogNumber">The catalog number of the album. Optional.</param>
|
||||
/// <param name="MusicBrainzReleaseId">The MusicBrainz identifier of the release. Optional.</param>
|
||||
/// <param name="MusicBrainzReleaseGroupId">The MusicBrainz identifier of the release group. Optional.</param>
|
||||
/// <param name="MusicBrainzReleaseArtistId">The MusicBrainz identifier of the release artist. Optional.</param>
|
||||
/// <param name="Contributors">The list of media contributors that performed on the album. Optional.</param>
|
||||
/// <param name="Ratings">The list of ratings for this album. Required.</param>
|
||||
[DebuggerDisplay("Title: {Metadata.Title}")]
|
||||
public record UpdateAlbumRequest(
|
||||
AlbumMetadataDto? Metadata,
|
||||
MusicMediaFormat? MediaFormat,
|
||||
string? Barcode,
|
||||
string? CatalogNumber,
|
||||
Guid? MusicBrainzReleaseId,
|
||||
Guid? MusicBrainzReleaseGroupId,
|
||||
Guid? MusicBrainzReleaseArtistId,
|
||||
List<MediaContributorReferenceDto>? Contributors,
|
||||
List<AudioRatingDto>? Ratings
|
||||
);
|
||||
Reference in new issue
Block a user