private IQueryable <T> ApplySpecification(ISpecification <T> spec) { return(SpecificationEvaluator <T> .GetQuery(_context.Set <T>().AsQueryable(), spec)); }
private IQueryable <T> ApplySpecification(ISpecification <T> spec) { return(SpecificationEvaluator <T> .GetQuery(_context.Set <T>().AsQueryable(), spec)); // product is converted into a Queryable }
private IQueryable <T> EvaluateExpression(ISpecification <T> spec) { return(SpecificationEvaluator <T> .GenerateExpression(_context.Set <T>(), spec)); }
private IQueryable <T> ApplySpecification(ISpecification <T> spec) { var evaluator = new SpecificationEvaluator <T>(); return(evaluator.GetQuery(_dbContext.Set <T>().AsQueryable(), spec)); }
protected IQueryable <T> ApplySpecficiation(ISpecification <T> spec, bool isGetCount = false) { return(SpecificationEvaluator <T> .GetQuery(this._context, spec, isGetCount)); }
private IQueryable <TEntity> ApplySpecification(ISpecification <TEntity> specification) { return(SpecificationEvaluator <TEntity> .Evaluate(specification, _context)); }
private IQueryable <T> ApplySpecification(ISpecification <T> spec) { return(SpecificationEvaluator <T> .GetQuery(_context.Set <T>().AsQueryable(), spec)); //here we have an IQueryable with those expressions that we can then pass to our database }
// 38-1 Apply specification private IQueryable <T> ApplySpecification(ISpecification <T> spec) { // get the evaluated IQueryable for the setted T type model for the specific specification spec. // here is where the EF context mix w/ the personalized IQueryable(The Specification). return(SpecificationEvaluator <T> .GetQuery(_context.Set <T>().AsQueryable(), spec)); }
public IQueryable <T> ApplySpecification(ISpecification <T> spec, CancellationToken ct) { return(SpecificationEvaluator <T> .GetQuery(_dbContext.Set <T>().AsQueryable(), spec)); }
private IQueryable <T> ApplySpecification(ISpecification <T> spec) => SpecificationEvaluator <T> .GetQuery(Context.Set <T>().AsQueryable(), spec);
//we have access to T, this will be replaced with product for example private IQueryable <T> ApplySpecification(ISpecification <T> spec) { //we are using set method to set the type of property this is //T is for example product return(SpecificationEvaluator <T> .GetQuery(_context.Set <T>().AsQueryable(), spec)); }
private IQueryable <T> ApplySpecification <T>(ISpecification <T> spec) where T : BaseEntity { return(SpecificationEvaluator.GetQuery(_dbContext.Set <T>().AsQueryable(), spec)); }
private IQueryable <T> ApplySpecification(ISpecification <T> spec) { // System.Console.WriteLine("Specs: " + spec.Criteria); return(SpecificationEvaluator <T> .GetQuery(_context.Set <T>().AsQueryable(), spec)); }
private IQueryable <T> Applyspcification(ISpecificationRepository <T> specification) { return(SpecificationEvaluator <T> .GetQuery(_storeContext.Set <T>().AsQueryable(), specification)); }
//this is related to the Pagination class in the Helper folder: public async Task <int> CountAsync(ISpecification <T> ISpecification) { //count the number of result returned (using microsoft .CountAsync() function) (our function name is also CountAsync()) return(await SpecificationEvaluator <T> .GetQuery(_Context.Set <T>().AsQueryable(), ISpecification).CountAsync()); }
private IQueryable <T> ApplySpecification(ISpecification <T> spec) => SpecificationEvaluator <T, TPrimaryKey> .GetQuery(_storeContext.Set <T>().AsQueryable(), spec);