//=============================================================================== // CREATE ORDER WISH LIST public void CreateOrder() { int totalMealNum = PromptForInteger("Enter a total number of meals you wish to order:"); int vegMealNum = PromptForInteger("Enter a number of vegetarian meals you wish to order:"); int gluten3MealNum = PromptForInteger("Enter a number of gluten-free meals you wish to order:"); int nut3MealNum = PromptForInteger("Enter a number of nut-free meals you wish to order:"); int fish3MealNum = PromptForInteger("Enter a number of fish-free meals you wish to order:"); try { OrderWishList = new OrderWishList(vegMealNum, gluten3MealNum, nut3MealNum, fish3MealNum, totalMealNum); } catch (Exception e) { PrintDivider(); Console.WriteLine(e.Message); Console.WriteLine("Please try again..."); CreateOrder(); } }
public OrderProcessor(OrderWishList orderWishList, RestaurantsFactory factory) { OrderWishList = orderWishList; SetListOfRestaurants(factory.ListOfRestaurants); ProcessOrder(); }