예제 #1
0
        public TurmaController()
        {
            var factory = new DatabaseFactory();

            var unitOfWork = new UnitOfWork(factory);

            var turmaRepository = new TurmaRepository(factory);

            _turmaService = new TurmaService(turmaRepository, unitOfWork);
        }
예제 #2
0
        public ChamadaController()
        {
            var factory = new DatabaseFactory();
            var aulaRespository = new AulaRepository(factory);
            var alunoRepository = new AlunoRepository(factory);
            var turmaRepository = new TurmaRepository(factory);
            var uow = new UnitOfWork(factory);

            _aulaService = new AulaService(aulaRespository, alunoRepository, turmaRepository, uow);
        }
예제 #3
0
        public AlunoController()
        {
            var factory = new DatabaseFactory();

            var alunoRespository = new AlunoRepository(factory);

            var turmaRepository = new TurmaRepository(factory);

            var uow = new UnitOfWork(factory);

            _alunoService=new AlunoService(alunoRespository,turmaRepository,uow);
        }
예제 #4
0
        public AlunoDataManager()
        {
            var factory = new DatabaseFactory();

            var unitOfWork = new UnitOfWork(factory);

            var alunoRepository = new AlunoRepository(factory);

            var turmaRepository = new TurmaRepository(factory);

            _turmaService = new TurmaService(turmaRepository, unitOfWork);

            _alunoService = new AlunoService(alunoRepository, turmaRepository, unitOfWork);

            _control = new AlunoControl(_alunoService);
        }
예제 #5
0
        public AlunoDialog(IEnumerable<TurmaDTO> turmas)
        {
            var factory = new DatabaseFactory();

            var unitOfWork = new UnitOfWork(factory);

            var alunoRepository = new AlunoRepository(factory);

            var turmaRepository = new TurmaRepository(factory);

            _alunoService = new AlunoService(alunoRepository, turmaRepository, unitOfWork);

            InitializeComponent();

            cmbTurmas.Items.Clear();

            foreach (var turma in turmas)
            {
                cmbTurmas.Items.Add(turma);
            }
        }
예제 #6
0
        public Principal()
        {
            InitializeComponent();

            _instance = this;

            var factory = new DatabaseFactory();

            var unitOfWork = new UnitOfWork(factory);

            var turmaRepository = new TurmaRepository(factory);

            var alunoRepository = new AlunoRepository(factory);

            _turmaService = new TurmaService(turmaRepository, unitOfWork);

            _alunoService = new AlunoService(alunoRepository, turmaRepository, unitOfWork);

            AtualizaListaTurmas();

            SelecionaTurmaAnoAtual();
        }
예제 #7
0
        public DatabaseFixture()
        {
            Factory = new DatabaseFactory();

            UnitOfWork = new UnitOfWork(Factory);
        }