public PresencaServiceTests() { _alunoRepository = new Mock<IAlunoRepository>(); _aulaRepository = new Mock<IAulaRepository>(); _turmaRepository = new Mock<ITurmaRepository>(); aulaService = new AulaService(_aulaRepository.Object, _alunoRepository.Object, _turmaRepository.Object); }
public Home() { InitializeComponent(); this.grafoService = DependencyFactory.Resolve <IGrafoService>(); this.aulaService = DependencyFactory.Resolve <IAulaService>(); this.dataBaseService = DependencyFactory.Resolve <IDataBaseService>(); try { Configuracoes.CarregarInfosArquivo(); this.IniciarConexaoBanco(); } catch { DialogResult resultado = MessageBox.Show("Falha na leitura do arquivo de configuração. " + "Deseja abrir as configurações agora ?", "Config file", MessageBoxButtons.YesNo, MessageBoxIcon.Question); if (resultado == DialogResult.Yes) { this.configuracoes.ShowDialog(); } else { return; } } try { this.login = new Login(); this.sobre = new Sobre(); this.buscarUsuario = new BuscaUsuario(); this.cadastroUsuario = new FormUsuario(0); this.editarUsuario = new FormEditarUsuario(); this.buscarPerfil = new BuscarPerfil(); this.formperfil = new FormEditarPerfil(); this.login.FormClosed += Login_FormClosed; this.editarUsuario.FormClosed += EditarUsuario_FormClosed; this.periodos = new HashSet <string>(); this.materias = new HashSet <string>(); this.professores = new HashSet <string>(); this.dias = new HashSet <string>(); this.horarios = new HashSet <string>(); this.AcoesLogout(); } catch { DialogResult resultado = MessageBox.Show("Houve um problema na abertura do sistema. conecte ao banco e abra o aplicativo novamente", "Config file", MessageBoxButtons.OK, MessageBoxIcon.Question); this.Close(); } this.btnCadastrar.Visible = false; this.btnBuscarUsuario.Visible = false; this.btnPerfil.Visible = false; }
public AulasController(INotificator notificator, IMapper mapper, IAulaService aulaService, IAulaRepository aulaRepository) : base(notificator) { _mapper = mapper; _aulaService = aulaService; _aulaRepository = aulaRepository; }
public AulaServiceTest() { _unitOfWork = new Mock<IUnitOfWork>(); _aulaRepository = new Mock<IAulaRepository>(); _alunoRepository = new Mock<IAlunoRepository>(); _turmaRepository = new Mock<ITurmaRepository>(); _aulaService = new AulaService(_aulaRepository.Object, _alunoRepository.Object, _turmaRepository.Object, _unitOfWork.Object); }
public AulaDataManager() { var unitOfWork = Injection.Get<IUnitOfWork>(); var aulaRepository = Injection.Get<IAulaRepository>(); var alunoRepository = Injection.Get<IAlunoRepository>(); var turmaRepository = Injection.Get<ITurmaRepository>(); _aulaService = new AulaService(aulaRepository, alunoRepository, turmaRepository, unitOfWork); _alunoService = new AlunoService(alunoRepository, turmaRepository, unitOfWork); _turmaService = new TurmaService(turmaRepository, unitOfWork); _control = new AulaControl(_aulaService); }
public AulaDataManager() { var unitOfWork = Injection.Get <IUnitOfWork>(); var aulaRepository = Injection.Get <IAulaRepository>(); var alunoRepository = Injection.Get <IAlunoRepository>(); var turmaRepository = Injection.Get <ITurmaRepository>(); _aulaService = new AulaService(aulaRepository, alunoRepository, turmaRepository, unitOfWork); _alunoService = new AlunoService(alunoRepository, turmaRepository, unitOfWork); _turmaService = new TurmaService(turmaRepository, unitOfWork); _control = new AulaControl(_aulaService); }
public void initialize() { AlunoService = new AlunoService( AlunoRepository.Object, TurmaRepository.Object, UnitOfWork.Object ); AulaService = new AulaService( AulaRepository.Object, AlunoRepository.Object, TurmaRepository.Object, UnitOfWork.Object ); TurmaService = new TurmaService( TurmaRepository.Object, UnitOfWork.Object ); }
public AulaDataManager() { var factory = new DatabaseFactory(); var unitOfWork = new UnitOfWork(factory); var aulaRepository = new AulaRepository(factory); var turmaRepository = new TurmaRepository(factory); var alunoRepository = new AlunoRepository(factory); _aulaService = new AulaService(aulaRepository, alunoRepository, turmaRepository, unitOfWork); _alunoService = new AlunoService(alunoRepository, turmaRepository, unitOfWork); _turmaService = new TurmaService(turmaRepository, unitOfWork); _control = new AulaControl(_aulaService); }
public Home() { InitializeComponent(); this.grafoService = DependencyFactory.Resolve <IGrafoService>(); this.aulaService = DependencyFactory.Resolve <IAulaService>(); try { this.periodos = new HashSet <string>(); this.materias = new HashSet <string>(); this.professores = new HashSet <string>(); this.dias = new HashSet <string>(); this.horarios = new HashSet <string>(); } catch { DialogResult resultado = MessageBox.Show("Houve um problema na abertura do sistema.", "Config file", MessageBoxButtons.OK, MessageBoxIcon.Question); this.Close(); } }
public CursadaController(ICursadaService cursadaService, IAulaService aulaService) { _cursadaService = cursadaService; _aulaService = aulaService; }
public AulaApplication(IAulaService service) : base(service) { _service = service; }
public AulaAppService(IAulaService aulaService) : base(aulaService) { _aulaService = aulaService; }
public AulaController(IAulaService aulaService) { _aulaService = aulaService; }
public AulaControl(IAulaService aulaService) : this() { this._aulaService = aulaService; }