Descriptions for Records and DTOs

This commit is contained in:
2025-09-06 16:40:19 +02:00
parent 09e6b07186
commit d4ea40a875
9 changed files with 87 additions and 19 deletions

View File

@@ -1,14 +1,21 @@
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
namespace API.Controllers.DTOs;
public sealed record FileLibrary(string Key, string BasePath, string LibraryName) : Identifiable(Key)
{
[StringLength(256)]
/// <summary>
/// The directory Path of the library
/// </summary>
[Required]
[Description("The directory Path of the library")]
public string BasePath { get; internal set; } = BasePath;
[StringLength(512)]
/// <summary>
/// The Name of the library
/// </summary>
[Required]
[Description("The Name of the library")]
public string LibraryName { get; internal set; } = LibraryName;
}