Пример #1
0
        private int RollBall(int noOfPins, int noOfTimes, IBowlingService bowling)
        {
            var score = 0;

            for (var i = 0; i < noOfTimes; i++)
            {
                score = bowling.RollBall(noOfPins);
            }
            return(score);
        }
Пример #2
0
 public BowlingController(IBowlingService bowlingService)
 {
     _bowlingService = bowlingService;
 }
 public BowlingGameController(IBowlingService bowlingService)
 {
     currentGame = bowlingService;
 }
Пример #4
0
 public TimedService(IBowlingService service) => decoratedService = service;
Пример #5
0
 internal LogService(IBowlingService service) => decoratedService = service;