refactor: Umbenennung der ReadAll-Methode in ReadOnly im CRUDRepository
This commit is contained in:
parent
b91769d931
commit
bb39b97d1e
@ -57,13 +57,13 @@ namespace DigitalData.Core.Infrastructure
|
||||
/// The result is not tracked by the context, which improves performance when you only need to read data without making modifications.
|
||||
/// </remarks>
|
||||
/// <returns>An <see cref="IQueryable{TEntity}"/> containing all entities of type <typeparamref name="TEntity"/>.</returns>
|
||||
protected virtual IQueryable<TEntity> ReadAll() => _dbSet.AsNoTracking();
|
||||
protected virtual IQueryable<TEntity> ReadOnly() => _dbSet.AsNoTracking();
|
||||
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves all entities of type TEntity.
|
||||
/// </summary>
|
||||
/// <returns>An enumerable of all entities in the database.</returns>
|
||||
public virtual async Task<IEnumerable<TEntity>> ReadAllAsync() => await ReadAll().ToListAsync();
|
||||
public virtual async Task<IEnumerable<TEntity>> ReadAllAsync() => await ReadOnly().ToListAsync();
|
||||
|
||||
/// <summary>
|
||||
/// Asynchronously updates an existing entity in the repository.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user