static void Main(string[] args) { ModelS model = new ModelS(); InterFace view = new InterFace(model); Controler ctrl = new Controler(model, view); ctrl.Start(); }
public ControllerViewModel() { model = new ModelS(); getSaveWorkList(); currentSaveWork = new SaveWork(); saveCommand = new RelayCommand(saveCreate); lunchSaveCommand = new RelayCommand(lunchSave); lunchAllSaveCommand = new RelayCommand(lunchAllSaveSyc); currentFile = new CrypteFile(); cryptCommand = new RelayCommand(cryptFile); currentProcessTrack = new ProcessTrack(); processCommand = new RelayCommand(isOnProcess); currentPriority = new Priority(); priorityCommand = new RelayCommand(isPropretyCheck); }
public override _Car ManufactureCar(CarModels carModel, List <CarExtras> carExtras) { _Car car = null; if (carModel == CarModels.ModelS) { car = new ModelS(); } else if (carModel == CarModels.Roadster) { car = new Roadster(); } //Notice that the Cybertruck is missing here, so we cant manufacture it! if (car == null) { Debug.Log("Sorry but this factory cant manufacture this model :("); return(car); } //Add the extras foreach (CarExtras carExtra in carExtras) { if (carExtra == CarExtras.DracoThruster) { car = new DracoThruster(car, 1); } else if (carExtra == CarExtras.EjectionSeat) { car = new EjectionSeat(car, 1); } else { Debug.Log("Sorry but this factory cant add this car extra :("); } } return(car); }
public override _Car ManufactureCar(CarModels carModel, List <CarExtras> carExtras) { _Car car = null; if (carModel == CarModels.Cybertruck) { car = new Cybertruck(); } else if (carModel == CarModels.ModelS) { car = new ModelS(); } else if (carModel == CarModels.Roadster) { car = new Roadster(); } if (car == null) { Debug.Log("Sorry but this factory cant manufacture this model :("); return(car); } //Add the extras foreach (CarExtras carExtra in carExtras) { if (carExtra == CarExtras.DracoThruster) { car = new DracoThruster(car, 1); } //Ejection seats are not legal in US so cant manufacture it (but we will still manufacture the rest of the car) else { Debug.Log("Sorry but this factory cant add this car extra :("); } } return(car); }
public InterFace(ModelS _model) { this.model = _model; }
public Controler(ModelS model, InterFace view) { this.model = model; this.view = view; }