예제 #1
0
        //----------------------------------------------------------------//

        public FeedManager(ISession session, IServiceProvider provider)
        {
            _commandFactory = provider.GetService <ICommandFactory>();
            _queryFactory   = provider.GetService <IQueryFactory>();

            _genreCommand      = _commandFactory.CreateCommand <IGenreCommand>(session);
            _companyCommand    = _commandFactory.CreateCommand <ICompanyCommand>(session);
            _countryCommand    = _commandFactory.CreateCommand <ICountryCommand>(session);
            _peopleCommad      = _commandFactory.CreateCommand <IPeopleCommand>(session);
            _movieCommand      = _commandFactory.CreateCommand <IMovieCommand>(session);
            _castCommand       = _commandFactory.CreateCommand <ICastCommand>(session);
            _crewCommand       = _commandFactory.CreateCommand <ICrewCommand>(session);
            _jobCommand        = _commandFactory.CreateCommand <IJobCommand>(session);
            _departmentCommand = _commandFactory.CreateCommand <IDepartmentCommand>(session);

            _movieGenreCommand   = _commandFactory.CreateCommand <IMovieGenreCommand>(session);
            _movieCompanyCommand = _commandFactory.CreateCommand <IMovieCompanyCommand>(session);
            _movieCountryCommand = _commandFactory.CreateCommand <IMovieCountryCommand>(session);

            _movieCountryQuery = _queryFactory.CreateQuery <IMovieCountryQuery>(session);
            _movieCompanyQuery = _queryFactory.CreateQuery <IMovieCompanyQuery>(session);
            _movieGenreQuery   = _queryFactory.CreateQuery <IMovieGenreQuery>(session);

            _movieQuery      = _queryFactory.CreateQuery <IMovieQuery>(session);
            _genreQuery      = _queryFactory.CreateQuery <IGenreQuery>(session);
            _companyQuery    = _queryFactory.CreateQuery <ICompanyQuery>(session);
            _countryQuery    = _queryFactory.CreateQuery <ICountryQuery>(session);
            _castQuery       = _queryFactory.CreateQuery <ICastQuery>(session);
            _crewQuery       = _queryFactory.CreateQuery <ICrewQuery>(session);
            _peopleQuery     = _queryFactory.CreateQuery <IPeopleQuery>(session);
            _jobQuery        = _queryFactory.CreateQuery <IJobQuery>(session);
            _departmentQuery = _queryFactory.CreateQuery <IDepartmentQuery>(session);

            _loadDataService = provider.GetRequiredService <ILoadDataService>();
        }
예제 #2
0
 public DepartmentsController(IMapper mapper,
                              IDepartmentQuery departmentQuery,
                              IDepartmentRepository departmentRepository)
 {
     _mapper               = mapper;
     _departmentQuery      = departmentQuery;
     _departmentRepository = departmentRepository;
 }
 public DataQueryService(IDeansOfficeQuery deansOfficeQuery, ILoginQueryDao loginQuery, ISessionGenerator sessionGenerator, IEventsQuery eventsQuery, IMessageQuery messageQuery, ILibraryQuery libraryQuery, IUnitQuery unitQuery, IUserQuery userQuery, IDepartmentQuery departmentQuery)
 {
     _deansOfficeQuery = deansOfficeQuery ?? new DeansOfficeQuery();
     _loginQuery       = loginQuery ?? new LoginQueryDao();
     _sessionGenerator = sessionGenerator ?? new SessionGenerator();
     _eventsQuery      = eventsQuery ?? new EventsQueryDao();
     _messageQuery     = messageQuery ?? new MessageQueryDao();
     _libraryQuery     = libraryQuery ?? new LibraryQueryDao();
     _unitQuery        = unitQuery ?? new UnitQueryDao();
     _userQuery        = userQuery ?? new UserQueryDao();
     _departmentQuery  = departmentQuery ?? new DepartmentQueryDao();
 }
예제 #4
0
 public DepartmentService(IDepartmentQuery departmentQuery, IDepartmentRepository departmentRepository, IDepartmentValidator departmentValidator)
 {
     _departmentQuery      = departmentQuery;
     _departmentRepository = departmentRepository;
     _departmentValidator  = departmentValidator;
 }