Replaces MVC with FastEndpoints in Lumina.Presentation.Api

This commit is contained in:
BinaryAlley committed 2024-10-23 21:34:10 +03:00
1 parent b1a20716df
commit c7b8bc2f1c
519 files changed
+15329 -8539

No files matched your search

@@ -0,0 +1,17 @@
#region ========================================================================= USING =====================================================================================
using System.Diagnostics;
using System.Text.Json.Serialization;
#endregion
namespace Lumina.Contracts.Requests.FileSystemManagement.Directories;
/// <summary>
/// Represents a request to get the directories of a file system path.
/// </summary>
/// <param name="Path">The file system path for which to get the directories.</param>
/// <param name="IncludeHiddenElements">Whether to include hidden file system elements or not.</param>
[DebuggerDisplay("Path: {Path}")]
public record GetDirectoriesRequest(
string? Path,
bool IncludeHiddenElements
);
@@ -0,0 +1,19 @@
#region ========================================================================= USING =====================================================================================
using System.Diagnostics;
using System.Text.Json.Serialization;
#endregion
namespace Lumina.Contracts.Requests.FileSystemManagement.Directories;
/// <summary>
/// Represents a request to get the tree of directories that make up a file system path.
/// </summary>
/// <param name="Path">The file system path for which to get the directory tree.</param>
/// <param name="IncludeFiles">Whether to include files along the directories or not.</param>
/// <param name="IncludeHiddenElements">Whether to include hidden file system elements or not.</param>
[DebuggerDisplay("Path: {Path}")]
public record GetDirectoryTreeRequest(
string? Path,
bool IncludeFiles,
bool IncludeHiddenElements
);
@@ -0,0 +1,17 @@
#region ========================================================================= USING =====================================================================================
using System.Diagnostics;
using System.Text.Json.Serialization;
#endregion
namespace Lumina.Contracts.Requests.FileSystemManagement.Directories;
/// <summary>
/// Represents a request to get the directories of a file system path.
/// </summary>
/// <param name="Path">The file system path for which to get the directory tree.</param>
/// <param name="IncludeHiddenElements">Whether to include hidden file system elements or not.</param>
[DebuggerDisplay("Path: {Path}")]
public record GetTreeDirectoriesRequest(
string? Path,
bool IncludeHiddenElements
);
@@ -0,0 +1,17 @@
#region ========================================================================= USING =====================================================================================
using System.Diagnostics;
using System.Text.Json.Serialization;
#endregion
namespace Lumina.Contracts.Requests.FileSystemManagement.Files;
/// <summary>
/// Represents a request to get the files at a file system path.
/// </summary>
/// <param name="Path">The file system path for which to get the files.</param>
/// <param name="IncludeHiddenElements">Whether to include hidden file system elements or not.</param>
[DebuggerDisplay("Path: {Path}")]
public record GetFilesRequest(
string? Path,
bool IncludeHiddenElements
);
@@ -0,0 +1,17 @@
#region ========================================================================= USING =====================================================================================
using System.Diagnostics;
using System.Text.Json.Serialization;
#endregion
namespace Lumina.Contracts.Requests.FileSystemManagement.Files;
/// <summary>
/// Represents a request to get the files of a file system path.
/// </summary>
/// <param name="Path">The file system path for which to get the tree files.</param>
/// <param name="IncludeHiddenElements">Whether to include hidden file system elements or not.</param>
[DebuggerDisplay("Path: {Path}")]
public record GetTreeFilesRequest(
string? Path,
bool IncludeHiddenElements
);
@@ -0,0 +1,17 @@
#region ========================================================================= USING =====================================================================================
using System.Diagnostics;
using System.Text.Json.Serialization;
#endregion
namespace Lumina.Contracts.Requests.FileSystemManagement.Path;
/// <summary>
/// Represents a request to check the existence of a file system path.
/// </summary>
/// <param name="Path">The file system path to check the exitence of.</param>
/// <param name="IncludeHiddenElements">Whether to include hidden elements in the search results, or not.</param>
[DebuggerDisplay("Path: {Path}, IncludeHiddenElements: {IncludeHiddenElements}")]
public record CheckPathExistsRequest(
string? Path,
bool IncludeHiddenElements
);
@@ -0,0 +1,17 @@
#region ========================================================================= USING =====================================================================================
using System.Diagnostics;
using System.Text.Json.Serialization;
#endregion
namespace Lumina.Contracts.Requests.FileSystemManagement.Path;
/// <summary>
/// Represents a request to get the root of a file system path.
/// </summary>
/// <param name="OriginalPath">The file system path to combine to.</param>
/// <param name="NewPath">The file system path to combine with.</param>
[DebuggerDisplay("OriginalPath: {OriginalPath}, NewPath: {NewPath}")]
public record CombinePathRequest(
string? OriginalPath,
string? NewPath
);
@@ -0,0 +1,15 @@
#region ========================================================================= USING =====================================================================================
using System.Diagnostics;
using System.Text.Json.Serialization;
#endregion
namespace Lumina.Contracts.Requests.FileSystemManagement.Path;
/// <summary>
/// Represents a request to get the root of a file system path.
/// </summary>
/// <param name="Path">The file system path for which to get the root.</param>
[DebuggerDisplay("Path: {Path}")]
public record GetPathParentRequest(
string? Path
);
@@ -0,0 +1,15 @@
#region ========================================================================= USING =====================================================================================
using System.Diagnostics;
using System.Text.Json.Serialization;
#endregion
namespace Lumina.Contracts.Requests.FileSystemManagement.Path;
/// <summary>
/// Represents a request to get the root of a file system path.
/// </summary>
/// <param name="Path">The file system path for which to get the root.</param>
[DebuggerDisplay("Path: {Path}")]
public record GetPathRootRequest(
string? Path
);
@@ -0,0 +1,15 @@
#region ========================================================================= USING =====================================================================================
using System.Diagnostics;
using System.Text.Json.Serialization;
#endregion
namespace Lumina.Contracts.Requests.FileSystemManagement.Path;
/// <summary>
/// Represents a request to split a file system path.
/// </summary>
/// <param name="Path">The file system path for which to get the path segments.</param>
[DebuggerDisplay("Path: {Path}")]
public record SplitPathRequest(
string? Path
);
@@ -0,0 +1,15 @@
#region ========================================================================= USING =====================================================================================
using System.Diagnostics;
using System.Text.Json.Serialization;
#endregion
namespace Lumina.Contracts.Requests.FileSystemManagement.Path;
/// <summary>
/// Represents a request to check the validity of a file system path.
/// </summary>
/// <param name="Path">The file system path to validate.</param>
[DebuggerDisplay("Path: {Path}")]
public record ValidatePathRequest(
string? Path
);
@@ -0,0 +1,17 @@
#region ========================================================================= USING =====================================================================================
using System.Diagnostics;
using System.Text.Json.Serialization;
#endregion
namespace Lumina.Contracts.Requests.FileSystemManagement.Thumbnails;
/// <summary>
/// Represents a request to get the thumbnail of a file system file.
/// </summary>
/// <param name="Path">The path of the file for which to get the thumbnail.</param>
/// <param name="Quality">The quality to use for the thumbnail.</param>
[DebuggerDisplay("Path: {Path}")]
public record GetThumbnailRequest(
string? Path,
int Quality
);