Exemple #1
0
 public IList <Product> FindProductsByColorOrSize(ProductColor color, ProductSize size)
 {
     return(_products.Where(product => product.Color == color || product.Size == size).ToList());
 }
Exemple #2
0
 public IList <Product> FindProductsByColor(ProductColor color)
 {
     return(_products.Where(product => product.Color == color).ToList());
 }
Exemple #3
0
 public IList <Product> FindProductsByColorAndBelowPrice(ProductColor color, double price)
 {
     return(_products.Where(product => product.Color == color && product.Price < price).ToList());
 }
 public ColorSpecification(ProductColor productColor)
 {
     _productColor = productColor;
 }
 public ColorSpecification(ProductColor productColor)
 {
     _productColor = productColor;
 }
 public IList<Product> FindProductsByColorOrSize(ProductColor color, ProductSize size)
 {
     return _products.Where(product => product.Color == color || product.Size == size).ToList();
 }
 public IList<Product> FindProductsByColorAndBelowPrice(ProductColor color, double price)
 {
     return _products.Where(product => product.Color == color && product.Price < price).ToList();
 }
 public IList<Product> FindProductsByColor(ProductColor color)
 {
     return _products.Where(product => product.Color == color).ToList();
 }