private string PressButtonSwitch(string command, int part) { Controller controller = new Controller(); Switch switchClass = new Switch(); ICommand typeCommand = new SwitchGetStateCommand(switchClass); controller.setCommand(typeCommand); return(controller.SendCommand(part)); }
internal string CheckSwitch(int numberSwitch) { Controller controller = new Controller(); Switch swithClass = new Switch(); ICommand typeCommand = null; //typeCommand how SwitchGetStateCommand typeCommand = new SwitchGetStateCommand(swithClass); controller.setCommand(typeCommand); string retorno = controller.SendCommand(0); return(retorno); }