Show / Hide Table of Contents

Interface IReadOnlyBasicRepository<TEntity, TKey>

Inherited Members
IReadOnlyBasicRepository<TEntity>.GetListAsync(Boolean, CancellationToken)
IReadOnlyBasicRepository<TEntity>.GetCountAsync(CancellationToken)
IReadOnlyBasicRepository<TEntity>.GetPagedListAsync(Int32, Int32, String, Boolean, CancellationToken)
Namespace: Volo.Abp.Domain.Repositories
Assembly: Volo.Abp.Ddd.Domain.dll
Syntax
public interface IReadOnlyBasicRepository<TEntity, TKey> : IReadOnlyBasicRepository<TEntity>, IRepository where TEntity : class, IEntity<TKey>
Type Parameters
Name Description
TEntity
TKey

Methods

FindAsync(TKey, Boolean, CancellationToken)

Gets an entity with given primary key or null if not found.

Declaration
Task<TEntity> FindAsync(TKey id, bool includeDetails = true, CancellationToken cancellationToken = null)
Parameters
Type Name Description
TKey id

Primary key of the entity to get

System.Boolean includeDetails

Set true to include all children of this entity

CancellationToken cancellationToken

A System.Threading.CancellationToken to observe while waiting for the task to complete.

Returns
Type Description
Task<TEntity>

Entity or null

GetAsync(TKey, Boolean, CancellationToken)

Gets an entity with given primary key. Throws EntityNotFoundException if can not find an entity with given id.

Declaration
Task<TEntity> GetAsync(TKey id, bool includeDetails = true, CancellationToken cancellationToken = null)
Parameters
Type Name Description
TKey id

Primary key of the entity to get

System.Boolean includeDetails

Set true to include all children of this entity

CancellationToken cancellationToken

A System.Threading.CancellationToken to observe while waiting for the task to complete.

Returns
Type Description
Task<TEntity>

Entity

Extension Methods

AbpObjectExtensions.As<T>(Object)
AbpObjectExtensions.To<T>(Object)
AbpObjectExtensions.IsIn<T>(T, T[])
AbpObjectExtensions.If<T>(T, Boolean, Func<T, T>)
AbpObjectExtensions.If<T>(T, Boolean, Action<T>)
LockExtensions.Locking(Object, Action)
LockExtensions.Locking<T>(T, Action<T>)
LockExtensions.Locking<TResult>(Object, Func<TResult>)
LockExtensions.Locking<T, TResult>(T, Func<T, TResult>)
Back to top Powered by Volosoft