contains method

bool contains(
  1. PurchasableFood foodItem
)

Returns true if the cart contains the specified PurchasableFood item, false otherwise.

Implementation

bool contains(PurchasableFood foodItem) {
  return _items.contains(foodItem);
}