コード例 #1
0
 public HomeController(string homeName, TemperatureSensor tempSensor, AirConditioner airConditioner)
 {
     this.tempSensor     = tempSensor;
     this.airConditioner = airConditioner;
     Name = homeName;
     tempSensor.AddHandler(TemperatureChanged);
     CoolHome();
     new Thread(StartTempSensor).Start();
 }
コード例 #2
0
 public HomeController(string homeName, TemperatureSensor tempSensor) : this(homeName, tempSensor, new AirConditioner())
 {
 }