public MainWindow() { InitializeComponent(); AccuBatteryController accuBatteryController = new AccuBatteryController(this); DoorController doorController = new DoorController(this); nextCar = new Car(accuBatteryController, doorController, this); }
public MainWindow() { InitializeComponent(); AccubatteryController accubatterryController = new AccubatteryController(); DoorController doorController = new DoorController(); nextCar = new Car(); nextCar.setAccubaterryController(accubatterryController); nextCar.setDoorController(doorController); }
public void setDoorController(DoorController doorController) { this.doorController = doorController; }