예제 #1
0
        public void SetUp()
        {
            var serviceProvider = new ServiceCollection()
                                  .AddTransient <ITabletop, Tabletop.Tabletop>()
                                  .BuildServiceProvider();

            _tabletop = serviceProvider.GetService <ITabletop>();
        }
예제 #2
0
 public ToyRobotSimulator(IRobot robot, IInputParser parser, ITabletop tabletop)
 {
     this.robot    = robot ?? throw new ArgumentNullException(nameof(robot));
     this.parser   = parser ?? throw new ArgumentNullException(nameof(parser));
     this.tabletop = tabletop ?? throw new ArgumentNullException(nameof(tabletop));
 }
예제 #3
0
 public PlaceCommand(IRobot robot, ITabletop tabletop) : base(robot)
 {
     _tabletop = tabletop;
 }
예제 #4
0
 public DriverRobotToy(IToy toy, ITabletop tabletop)
 {
     robotToy      = toy;
     this.tabletop = tabletop;
 }
예제 #5
0
파일: Robot.cs 프로젝트: user5754/ToyRobot
 public Robot(ITabletop tabletop)
 {
     _tabletop = tabletop;
     isPlaced  = false;
 }