private IQueryable <TEntity> ApplySpec(ISpecification <TEntity> spec) { return(SpecEvaluator <TEntity> .GetQuery(_context.Set <TEntity>(), spec)); }
public async Task <int> CountAsync(ISpecification <TEntity> spec) { return(await SpecEvaluator <TEntity> .GetQuery(_context.Set <TEntity>(), spec, applyCritieriaOnly : true).CountAsync()); }
private IQueryable <T> ApplySpec(ISpec <T> spec) { return(SpecEvaluator <T> .GetQuery(_context.Set <T>().AsQueryable(), spec)); }