public void ShowClients() { ClientController clientController = new ClientController(); IViewClientsForm form = formFactory.CreateViewClientsForm(); clientController.ShowClients(form, clientRepository, this); }
public void ShowClients(IViewClientsForm form, IClientRepository clientRepository, IMainController mainController) { List <Client> clients = clientRepository.GetAllClients(); Subject subject = (Subject)clientRepository; subject.Attach((IObserver)form); form.ShowModaless(mainController, clients); }