Example #1
0
        public DrinkMaker(decimal currentMoney, Drink drink, ICoffeMachine coffeMachineService)
        {
            if (currentMoney < 0)
            {
                throw new ArgumentException(nameof(currentMoney));
            }
            if (drink == null)
            {
                throw new ArgumentNullException(nameof(drink));
            }
            if (coffeMachineService == null)
            {
                throw new ArgumentNullException(nameof(coffeMachineService));
            }

            _drink = drink;
            _coffeMachineService = coffeMachineService;
            _currentMoney        = currentMoney;
        }
Example #2
0
 public void MakeCoffee(ICoffeMachine _coffeeMachine)
 {
     _coffeeMachine.MakeCoffee();
 }
Example #3
0
 public Employee(ICoffeMachine coffeeMachine)
 {
     _coffeeMachine = coffeeMachine;
 }