public static IQueryable <TEntity> ApplyFilter <TEntity>(this IQueryable <TEntity> src, IQueryFilter <TEntity> filter) where TEntity : IDbEntity { if (filter != null) { src = filter.GetSatisfiedItems(src); } return(src); }