public boolean update(int id, int newQuantity) {
      Iterator<CartItem> iter = cart.iterator();
      while (iter.hasNext()) {
         CartItem item = iter.next();
         if (item.getId() == id) {
            // id found, increase qtyOrdered
            item.setQuantityOrdered(newQuantity);
            return true;
         }
      }
      return false;
   }