예제 #1
0
        public void SeedMenuList()
        {
            CafeMenuContent morningGlory = new CafeMenuContent(1, "The Morning Glory", "A breakfest burger to start your day off right.", "Bacon, egg, hash brown, lettuce, tomato, red onion, tomato relish & tarragon mayonnaise.", 10.95);
            CafeMenuContent eggsBenedict = new CafeMenuContent(2, "Eggs Benedict", "A traditional English eggs bene.", "Option of salmon, bacon or mushrooms on our house - made potato rosti topped with sauteed spinach and our house - made hollandaise.", 16.55);
            CafeMenuContent duckCurry    = new CafeMenuContent(3, "Duck Curry", "The famous homemade curry with select chilies, spices and seasonings.", "Crispy confit duck, seasonal vegetables, on a bed of coconut rice.", 14.39);

            AddContentToList(morningGlory);
            AddContentToList(eggsBenedict);
            AddContentToList(duckCurry);
        }
예제 #2
0
        public bool RemoveMenuItem(string mealName)
        {
            CafeMenuContent content = ReturnMealNames(mealName);

            if (content == null)
            {
                return(false);
            }

            int intialCount = _repoCafeContent.Count;

            _repoCafeContent.Remove(content);

            if (intialCount > _repoCafeContent.Count)
            {
                return(true);
            }
            else
            {
                return(false);
            }
        }
예제 #3
0
        //CRUD for Application

        public void AddContentToList(CafeMenuContent content)
        {
            _repoCafeContent.Add(content);
        }