public PizzaToMenuAdapter(IPizzaComponent pizza, string drink, double drinkPrice) { _food = pizza.ToString(); _drink = drink; _drinkPrice = drinkPrice; _totalPrice = _pizza.Price + _drinkPrice; }
private void preparePizza(IPizzaComponent p) { Task.Factory.StartNew(() => { int preparetime = random.Next(5, 15); System.Threading.Thread.Sleep(preparetime * 1000); NotifyObservers(p.ToString()); }); }
public override string ToString() { return(Pizza.ToString() + " and Pepperoni"); }
public override string ToString() { return(Pizza.ToString() + " and Chilli"); }