Standardizes the remaining boolean names across the stack

This commit is contained in:
BinaryAlley committed 2026-09-13 16:48:42 +03:00
1 parent 3e0c3b624f
commit 39f4a04459
40 files changed
+1062 -448

No files matched your search

@@ -1,7 +1,9 @@
#region ========================================================================= USING =====================================================================================
using Lumina.Domain.Common.Primitives;
using Lumina.Application.Common.DataAccess.Entities.Common;
using System.Collections.Generic;
using Lumina.Application.Common.DTO.Filtering;
using Lumina.Application.Common.DTO.Pagination;
using Lumina.Domain.SharedKernel.Common.Enums.Common;
using System.Threading;
using System.Threading.Tasks;
#endregion
@@ -9,15 +11,22 @@ using System.Threading.Tasks;
namespace Lumina.Application.Common.DataAccess.Repositories.Common.Actions;
/// <summary>
/// Interface defining the "get all" action for interacting with a generic persistance medium.
/// Interface defining the "get all" action for interacting with a generic persistence medium.
/// </summary>
/// <typeparam name="TModel">The type used as a result for the "get all" action. It should implement <see cref="IStorageEntity"/>.</typeparam>
public interface IGetAllRepositoryAction<TModel> where TModel : IStorageEntity
{
/// <summary>
/// Gets all data of type <typeparamref name="TModel"/> from the storage medium.
/// Gets data of type <typeparamref name="TModel"/> from the storage medium.
/// </summary>
/// <typeparam name="TFilter">The type of the filter carrying the criteria used to filter the results.</typeparam>
/// <param name="paginationData">The pagination data that includes the current page and the number of items per page to retrieve. If <see langword="null"/>, all matching data is returned.</param>
/// <param name="sortBy">The name of the field by which to sort the results.</param>
/// <param name="sortOrder">The direction in which to sort the results.</param>
/// <param name="filterModel">The model containing the parameters used to filter the results.</param>
/// <param name="shouldIncludeNavigationProperties">Whether the navigation properties of the entities should be loaded together with the entities themselves. Pass <see langword="false"/> to retrieve only the data stored directly on the entity rows.</param>
/// <param name="shouldTrackEntities">Whether the retrieved entities should be tracked by the persistence medium, so that changes to them can be saved. Pass <see langword="false"/> for read-only scenarios, to avoid the tracking overhead.</param>
/// <param name="cancellationToken">Cancellation token that can be used to stop the execution.</param>
/// <returns>An <see cref="Result{TValue}"/> containing either a collection of <typeparamref name="TModel"/>, or an error.</returns>
Task<Result<IEnumerable<TModel>>> GetAllAsync(CancellationToken cancellationToken);
/// <returns>An <see cref="Result{TValue}"/> containing either a paginated result of type <typeparamref name="TModel"/>, or an error.</returns>
Task<Result<PaginatedResultDto<TModel>>> GetAllAsync<TFilter>(PaginationDataDto? paginationData = null, string? sortBy = null, SortOrder? sortOrder = null, TFilter? filterModel = null, bool shouldIncludeNavigationProperties = true, bool shouldTrackEntities = true, CancellationToken cancellationToken = default) where TFilter : BaseFilterDto;
}
@@ -8,7 +8,7 @@ using System.Threading.Tasks;
namespace Lumina.Application.Common.DataAccess.Repositories.Common.Actions;
/// <summary>
/// Interface defining the "get by id" action for interacting with a generic persistance medium.
/// Interface defining the "get by id" action for interacting with a generic persistence medium.
/// </summary>
/// <typeparam name="TModel">The type used as a result for the "get by id" action. It should implement <see cref="IStorageEntity"/>.</typeparam>
/// <typeparam name="TId">The type used for the identifier of the respository. It should not be <see langword="null"/>.</typeparam>
@@ -19,7 +19,9 @@ public interface IGetByIdRepositoryAction<TModel, TId> where TModel : IStorageEn
/// Gets an element of type <typeparamref name="TModel"/> identified by <paramref name="id"/> from the storage medium.
/// </summary>
/// <param name="id">The id of the element to get.</param>
/// <param name="shouldIncludeNavigationProperties">Whether the navigation properties of the entity should be loaded together with the entity itself. Pass <see langword="false"/> to retrieve only the data stored directly on the entity row.</param>
/// <param name="shouldTrackEntities">Whether the retrieved entity should be tracked by the persistence medium, so that changes to it can be saved. Pass <see langword="false"/> for read-only scenarios, to avoid the tracking overhead.</param>
/// <param name="cancellationToken">Cancellation token that can be used to stop the execution.</param>
/// <returns>An <see cref="Result{TValue}"/> containing either a <typeparamref name="TModel"/> identified by <paramref name="id"/>, or an error.</returns>
Task<Result<TModel?>> GetByIdAsync(TId id, CancellationToken cancellationToken);
Task<Result<TModel?>> GetByIdAsync(TId id, bool shouldIncludeNavigationProperties = true, bool shouldTrackEntities = true, CancellationToken cancellationToken = default);
}