public Client() { DashBoardManager _dashBoardManager = new DashBoardManager(); DashBoard _tesladashboard = new DashBoard($"TESLA : \n"); Phone _phone = new Phone(_tesladashboard, "hello this is me \n"); PodCast _podCast = new PodCast(_tesladashboard, "hello this is a podcast in your tesla \n"); _dashBoardManager.AddAction(_phone); _dashBoardManager.AddAction(_podCast); _dashBoardManager.ProcessPendingTransaction(); System.Console.WriteLine(_tesladashboard.Display); }
public PodCast(DashBoard dashBoard, string voice) { this._dashBoard = dashBoard; this.Voice = voice; }
public Radio(DashBoard dashBoard, string voice) { this._dashBoard = dashBoard; this.Voice = voice; }
public Phone(DashBoard dashBoard, string voiceCall) { _dashBoard = dashBoard; VoiceCall = voiceCall; }