/// <summary>
        /// Создаёт стеклянные тарелки
        /// </summary>
        /// <param name="count"> Количество посуды </param>
        /// <returns> Посуду </returns>
        public Dish CreateBlackSmallGlassPlate(int count)
        {
            Dish answer;

            DishBuilder dishBuilder = new DishBuilder();

            dishBuilder.setCapacity(3);
            dishBuilder.setColor("black");
            dishBuilder.setMaterial("glass");
            dishBuilder.setPrice(60);

            answer = new Plate(dishBuilder.GetDishCharacteristics(), _lastId, count);
            _lastId++;

            return(answer);
        }
示例#2
0
 static void printPlate(Plate thisPlate)
 {
     if (thisPlate.IsSingleUse == true)
     {
         Console.WriteLine("Одноразовая тарелка:");
     }
     else
     {
         Console.WriteLine("Многоразовая тарелка:");
     }
     Console.WriteLine("В количестве - " + thisPlate.GetDishCount());
     Console.WriteLine("Айди выпуска - " + thisPlate.GetDishId());
     Console.WriteLine("Материал - " + thisPlate.GetDishCharacteristics().material);
     Console.WriteLine("Вместимость - " + thisPlate.GetDishCharacteristics().capacity);
     Console.WriteLine("Цвет - " + thisPlate.GetDishCharacteristics().color);
     Console.WriteLine("Цена - " + thisPlate.GetDishCharacteristics().price);
 }