Method GetList
GetList<T>(IEntityService<T>, CancellationToken)
Gets a list of entities of type T using the IEntityService.
public static Task<List<T>> GetList<T>(this IEntityService<T> entityService, CancellationToken cancellationToken = default) where T : class
Parameters
entityServiceIEntityService<T>The IEntityService instance.
cancellationTokenCancellationTokenThe cancellation token.
Returns
Type Parameters
TThe type of the entity.
GetList<T>(IEntityService<T>, Expression<Func<T, bool>>, CancellationToken)
Gets a list of entities of type T that satisfy the specified condition using the IEntityService.
public static Task<List<T>> GetList<T>(this IEntityService<T> entityService, Expression<Func<T, bool>> where, CancellationToken cancellationToken = default) where T : class
Parameters
entityServiceIEntityService<T>The IEntityService instance.
whereExpression<Func<T, bool>>The condition to satisfy.
cancellationTokenCancellationTokenThe cancellation token.
Returns
Type Parameters
TThe type of the entity.