public Food VeggieSelect(Food order) { if (order.GetType() == (typeof(Olives))) { Olives olives = new Olives(); return olives; } if (order.GetType() == (typeof(Lettuce))) { Lettuce lettuce = new Lettuce(); return lettuce; } if (order.GetType() == (typeof(Spinach))) { Spinach spinach = new Spinach(); return spinach; } if (order.GetType() == (typeof(Pickles))) { Pickles pickles = new Pickles(); return pickles; } else { Lettuce lettuce = new Lettuce(); return lettuce; } }
public Food BreadSelect(Food order) { if (order.GetType() == (typeof(SevenGrainWheatBread))) { SevenGrainWheatBread sevenWheat = new SevenGrainWheatBread(); return sevenWheat; } if (order.GetType() == (typeof(WheatBread))) { WheatBread wheat = new WheatBread(); return wheat; } if (order.GetType() == (typeof(Italian))) { Italian italian = new Italian(); return italian; } if (order.GetType() == (typeof(Tortilla))) { Tortilla tortilla = new Tortilla(); return tortilla; } else { Italian italian = new Italian(); return italian; } }
public Food MeatSelect(Food order) { if (order.GetType() == (typeof(Ham))) { Ham ham = new Ham(); return ham; } if (order.GetType() == (typeof(Turkey))) { Turkey turkey = new Turkey(); return turkey; } if (order.GetType() == (typeof(RoastBeef))) { RoastBeef beef = new RoastBeef(); return beef; } if (order.GetType() == (typeof(Salami))) { Salami salami = new Salami(); return salami; } if (order.GetType() == (typeof(Bacon))) { Bacon bacon = new Bacon(); return bacon; } else { Ham ham = new Ham(); return ham; } }
public Food DairySelect(Food order) { if (order.GetType() == (typeof(ShreddedCheddar))) { ShreddedCheddar shredChed = new ShreddedCheddar(); return shredChed; } if (order.GetType() == (typeof(Provolone))) { Provolone prov = new Provolone(); return prov; } if (order.GetType() == (typeof(CheddarJack))) { CheddarJack chedJack = new CheddarJack(); return chedJack; } if (order.GetType() == (typeof(ColbyJack))) { ColbyJack colbyJack = new ColbyJack(); return colbyJack; } else { ShreddedCheddar shredChed = new ShreddedCheddar(); return shredChed; } }
public Sauce SauceSelect(Food order) { if (order.GetType() == (typeof(Mayo))) { Mayo mayo = new Mayo(); return mayo; } if (order.GetType() == (typeof(ChipotleMayo))) { ChipotleMayo chipMayo = new ChipotleMayo(); return chipMayo; } else { Mayo mayo = new Mayo(); return mayo; } }
public Food FindItem(Food order) { if (order.GetType() == (typeof(Meat))) { MeatSelection meatChooser = new MeatSelection(); Food meat = meatChooser.MeatSelect(order); return meat; } if (order.GetType() == (typeof(Veggie))) { VeggieSelection veggieChooser = new VeggieSelection(); Food veggie = veggieChooser.VeggieSelect(order); return veggie; } if (order.GetType() == (typeof(Dairy))) { DairySelection dairyChooser = new DairySelection(); Food dairy = dairyChooser.DairySelect(order); return dairy; } if (order.GetType() == (typeof(Bread))) { BreadSelection breadChooser = new BreadSelection(); Food bread = breadChooser.BreadSelect(order); return bread; } if (order.GetType() == (typeof(Sauce))) { SauceSelection sauceChooser = new SauceSelection(); Food sauce = sauceChooser.SauceSelect(order); return sauce; } else { Lettuce lettuce = new Lettuce(); return lettuce; } }