From ce6736fd9abb0d4df48011db33c49e3f3cf10334 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Halil=20=C4=B0brahim=20Kalkan?= Date: Sun, 25 Jul 2021 12:14:10 +0300 Subject: [PATCH] Resolved #9646: Move GetListAsync from IReadOnlyBasicRepository to IReadOnlyRepository --- .../Repositories/IReadOnlyBasicRepository.cs | 18 ++---------------- .../Domain/Repositories/IReadOnlyRepository.cs | 15 +++++++++++++++ 2 files changed, 17 insertions(+), 16 deletions(-) diff --git a/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Repositories/IReadOnlyBasicRepository.cs b/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Repositories/IReadOnlyBasicRepository.cs index ed97d87ffa..a6988e5c10 100644 --- a/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Repositories/IReadOnlyBasicRepository.cs +++ b/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Repositories/IReadOnlyBasicRepository.cs @@ -1,6 +1,4 @@ -using System; -using System.Collections.Generic; -using System.Linq.Expressions; +using System.Collections.Generic; using System.Threading; using System.Threading.Tasks; using JetBrains.Annotations; @@ -18,19 +16,7 @@ namespace Volo.Abp.Domain.Repositories /// A to observe while waiting for the task to complete. /// Entity Task> GetListAsync(bool includeDetails = false, CancellationToken cancellationToken = default); - - /// - /// Gets a list entities by the given . - /// - /// A condition to find the entity - /// Set true to include all children of this entity - /// A to observe while waiting for the task to complete. - /// Entity - Task> GetListAsync( - [NotNull] Expression> predicate, - bool includeDetails = false, - CancellationToken cancellationToken = default); - + /// /// Gets total count of all entities. /// diff --git a/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Repositories/IReadOnlyRepository.cs b/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Repositories/IReadOnlyRepository.cs index 80d1425044..8b1ed23bc8 100644 --- a/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Repositories/IReadOnlyRepository.cs +++ b/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Repositories/IReadOnlyRepository.cs @@ -1,7 +1,10 @@ using System; +using System.Collections.Generic; using System.Linq; using System.Linq.Expressions; +using System.Threading; using System.Threading.Tasks; +using JetBrains.Annotations; using Volo.Abp.Domain.Entities; using Volo.Abp.Linq; @@ -23,6 +26,18 @@ namespace Volo.Abp.Domain.Repositories Task> WithDetailsAsync(params Expression>[] propertySelectors); //TODO: CancellationToken Task> GetQueryableAsync(); //TODO: CancellationToken + + /// + /// Gets a list entities by the given . + /// + /// A condition to find the entity + /// Set true to include all children of this entity + /// A to observe while waiting for the task to complete. + /// Entity + Task> GetListAsync( + [NotNull] Expression> predicate, + bool includeDetails = false, + CancellationToken cancellationToken = default); } public interface IReadOnlyRepository : IReadOnlyRepository, IReadOnlyBasicRepository