public ReadFacade( IMapper mapper, IReadRepository <Person> dbRepo) { this.mapper = mapper; this.dbRepo = dbRepo; }
public ProjectBusiness(IReadRepository readRepository, IRepository repository, IWriteRepository writeRepository, IUserAccessBusiness userAccessBusiness) { _readRepository = readRepository; _repository = repository; _writeRepository = writeRepository; _userAccessBusiness = userAccessBusiness; }
public RoadmapService( IMapper mapper, IReadRepository <RoadmapItemModel> roadmapRepository) { _roadmapRepository = Guard.Against.Null(roadmapRepository, nameof(roadmapRepository), nameof(IReadRepository <RoadmapItemModel>)); _mapper = Guard.Against.Null(mapper, nameof(mapper), nameof(IMapper)); }
public MembershipController(IHttpContextAccessor httpContextAccessor, UserManager <User> userManager, IMapper mapper, IReadRepository db) { _userId = userManager.GetUserId(httpContextAccessor.HttpContext.User); _mapper = mapper; _db = db; }
/// <summary> /// Constructor. /// </summary> /// <param name="configuration">Ranking configuration.</param> /// <param name="readRepository">Instance of <see cref="IReadRepository"/>.</param> /// <exception cref="ArgumentNullException"><paramref name="configuration"/> or inner value is <c>Null</c>.</exception> /// <exception cref="ArgumentNullException"><paramref name="readRepository"/> is <c>Null</c>.</exception> public StatisticsProvider( IReadRepository readRepository, IOptions <RankingConfiguration> configuration) { _readRepository = readRepository ?? throw new ArgumentNullException(nameof(readRepository)); _configuration = configuration?.Value ?? throw new ArgumentNullException(nameof(configuration)); }
/// <summary> /// Creates Room Controller. /// </summary> /// <param name="mappingConfig"></param> /// <param name="repository"></param> public RoomController( TypeAdapterConfig mappingConfig, IReadRepository <Room> repository) { MappingConfig = mappingConfig; Repository = repository; }
public CustomerEarningsService( IReadRepository <Customer> customerReadRepository, IWriteRepository <TotalEarningForCustomerInMonth> totalEarningWriteRepository) { _customerReadRepository = customerReadRepository; _totalEarningWriteRepository = totalEarningWriteRepository; }
public ChannelController(IChannelManager ChannelManager, IReadRepository <Read.Channel, int> readRepository, IWriteRepository <Write.Channel, int> writeRepository) { _ChannelManager = ChannelManager; _readRepository = readRepository; _writeRepository = writeRepository; }
public GetLabelsQueryHandler( IReadRepository<Label, Guid> labelRepository, IMapper mapper) { _labelRepository = labelRepository; _mapper = mapper; }
public GamesService( IMapper mapper, IReadRepository <GameModel> gamesRepository) { _mapper = mapper; _gamesRepository = gamesRepository; }
public MonitoQuery( IMapper mapper, IReadRepository <RequestPersistenceModel> requestRepository ) { Field <ListGraphType <RequestGraphType> >( "requests", resolve: context => requestRepository .FindAll() .ProjectTo <MinimalRequestApplicationModel>(mapper.ConfigurationProvider) ); Field <RequestGraphType>( "request", arguments: new QueryArguments( new QueryArgument <NonNullGraphType <IdGraphType> >() { Name = "id" } ), resolve: context => { var id = context.GetArgument <int>("id"); return(requestRepository .FindAll(x => x.ID == id) .ProjectTo <MinimalRequestApplicationModel>(mapper.ConfigurationProvider) .FirstOrDefault()); } ); }
public DeleteService(IMapper mapper, IReadRepository <TEntity> readRepository, IWriteRepository <TEntity> writeRepository, IModelValidator <TModel> validator) { _mapper = mapper; _readRepository = readRepository; _writeRepository = writeRepository; _validator = validator; }
public RaceService(Context context) { _context = context; _readRepository = new ReadRepository(_context); _readerRepository = new ReaderRepository(_context); _readingRepository = new ReadingRepository(_context); }
public UpdateTreatmentSessionBusinessValidator( IStringLocalizer <UpdateTreatmentSessionBusinessValidator> localizer, IStringLocalizer <TreatmentSessionBusinessValidator> addLocalizer, UpdateTreatmentSessionValidator simpleValidator, IReadRepository <TreatmentSession> treatmentSessionRepository) { RuleFor(m => m) .SetValidator(simpleValidator) .DependentRules(() => { RuleFor(m => m.ReferenceId) .MustAsync((m, ctx, ct) => ExistsTreatmentSession(m, ct)) .WithMessage(localizer[NotExistingTreatmentSessionMessageName]) .DependentRules(() => { RuleFor(m => m.PatientReferenceId) .MustAsync((m, ctx, ct) => HasNoOverlappingsForPatient(m, ct)) .WithMessage(addLocalizer[TreatmentSessionBusinessValidator.OverlappingTreatmentSessionForPatientMessageName]); RuleFor(m => m.DentalTeamReferenceId) .MustAsync((m, ctx, ct) => HasNoOverlappingsForDentalTeam(m, ct)) .WithMessage(addLocalizer[TreatmentSessionBusinessValidator.OverlappingTreatmentSessionForDentalTeamMessageName]); }); }); TreatmentSessionRepository = treatmentSessionRepository; }
public StudentCourseService(IReadRepository readRepository, IWriteRepository writeRepository, IStudentCourseMapper studentCourseMapper, ICourseMapper courseMapper) { this.readRepository = readRepository ?? throw new ArgumentNullException(); this.writeRepository = writeRepository ?? throw new ArgumentNullException(); this.studentCourseMapper = studentCourseMapper ?? throw new ArgumentNullException(); this.courseMapper = courseMapper ?? throw new ArgumentNullException(); }
public ServiceBase(IUnitOfWork unitOfWork, IReadUnit readUnit) { _unitOfWork = unitOfWork ?? throw new ArgumentException("Unit of Work"); _readUnit = readUnit ?? throw new ArgumentException("Read Unit"); _writeRepository = _unitOfWork.WriteRepository <T>(); _readRepository = _readUnit.ReadRepository <T>(); }
public LocationOverviewService( IMapper mapper, IReadRepository <LocationOverviewModel> locationOverviewRepository) { _mapper = Guard.Against.Null(mapper, nameof(mapper), nameof(IMapper)); _locationOverviewRepository = Guard.Against.Null(locationOverviewRepository, nameof(locationOverviewRepository), nameof(IReadRepository <LocationOverviewModel>)); }
public HomeController( ICreateRepository <Contract> createRepo, IReadRepository <Contract> readRepo, IUpdateRepository <Contract> updateRepo, IDeleteRepository <Contract> deleteRepo) : base(createRepo, readRepo, updateRepo, deleteRepo) { }
public ProfessorService(IReadRepository readRepository, IWriteRepository writeRepository, IProfessorMapper professorMapper) { this.writeRepository = writeRepository ?? throw new ArgumentNullException(); this.readRepository = readRepository ?? throw new ArgumentNullException(); this.professorMapper = professorMapper ?? throw new ArgumentNullException(); }
public PersonService( IReadRepository <Person> personRepository, IWriteRepository <Person> personWriteRepository) { _personRepository = personRepository; _personWriteRepository = personWriteRepository; }
public ReadTagsBackgroundService(IOptions <ReadTagsBackgroundSettings> options, IReadServiceBus readServiceBus, IReadRepository readRepository, ILogger <ReadTagsBackgroundService> logger) { _readTagsBackgroundSettings = options.Value; _readServiceBus = readServiceBus; _readRepository = readRepository; _logger = logger; }
public ReadingViewModel() { _context = new Context(); _readRepository = new ReadRepository(_context); Reads = new ObservableCollection <Read>(); Reads.CollectionChanged += ContentCollectionChanged; }
public void AddNewReadBook(IAddNewReadBookView inForm, IReadRepository readRepository) { if (inForm.ShowViewModal() == true) { try { string title = inForm.Title; string author = inForm.Author; string publisher = inForm.Publisher; DateTime datePub = inForm.DatePublished; int numPages = inForm.NumberOfPages; string genre = inForm.Genre; DateTime dateRead = inForm.DateRead; int rating = inForm.Rating; BookRead newRead = BookFactory.CreateBookRead(title, author, publisher, datePub, numPages, genre, dateRead, rating); readRepository.AddBookRead(newRead); } catch (Exception ex) { MessageBox.Show("EXCEPTION: " + ex.Message); throw; } } }
public UomReadController ( IReadRepository <Uom> repository, IPageLinksBuilder pageLinksBuilder ) : base(repository, pageLinksBuilder) { }
/// <summary> /// Creates Treatment Controller. /// </summary> /// <param name="mappingConfig"></param> /// <param name="repository"></param> public TreatmentController( TypeAdapterConfig mappingConfig, IReadRepository <Treatment> repository) { MappingConfig = mappingConfig; Repository = repository; }
/// <summary> /// Initializes a new instance of the <see cref="GetQueryHandler{TModel, TEntity}"/> class. /// </summary> /// <param name="repository">The entity repository.</param> /// <param name="mapper">The entity mapper.</param> public GetQueryHandler(IReadRepository <TEntity> repository, IMapper mapper) { Guard.ArgumentNotNull(repository, nameof(repository)); Guard.ArgumentNotNull(mapper, nameof(mapper)); _repository = repository; _mapper = mapper; }
public CompaniesController(IHttpContextAccessor accessor) { _accessor = accessor; _readRepository = DocumentDatabase.GetReadRepository <Company>(); _writeRepository = DocumentDatabase.GetWriteRepository <Company>(); }
public ProjectController(IProjectRepository projectrepo, IBaseRepository baserepo, IReadRepository <WTTESTEQUIPMENT> wtequipmentrepo, IReadRepository <WTTESTINFO> wttestinforepo) { projectrepository = projectrepo; baserepository = baserepo; this.wtequipmentrepo = wtequipmentrepo; this.wttestinforepo = wttestinforepo; }
public ArticlesController(IReadRepository readRepository, IEventRepository repository, ICheckpointPersister checkpointPersister) { this.readRepository = readRepository ?? throw new ArgumentNullException(nameof(readRepository)); this.repository = repository ?? throw new ArgumentNullException(nameof(repository)); this.checkpointPersister = checkpointPersister ?? throw new ArgumentNullException(nameof(checkpointPersister)); }
public BaseRepository(DbContext dbContext) { this.CreateRepository = new CreateRepository <T>(dbContext); this.UpdateRepository = new UpdateRepository <T>(dbContext); this.DeleteRepository = new DeleteRepository <T>(dbContext); this.ReadRepository = new ReadRepository <T>(dbContext); }
public BlogPostService( IReadRepository <BlogPost> readRepository, IWriteRepository <BlogPost> writeRepository) { _readRepository = readRepository; _writeRepository = writeRepository; }
public HomeController(IReadRepository ReadRepository, IUserProfileRepository UserProfileRepository, IPraiseRepository PraiseRepository) { this.UserProfileRepository = UserProfileRepository; this.ReadRepository = ReadRepository; this.PraiseRepository = PraiseRepository; }
static ServiceLocator() { if (IsInitialized) return; lock (LockThis) { ContainerBootstrapper.BootstrapStructureMap(); _commandBus = ObjectFactory.GetInstance<ICommandBus>(); _readModel = ObjectFactory.GetInstance<IReadRepository>(); IsInitialized = true; } }
public IssueTypeBusiness(IReadRepository readRepository, IUserAccessBusiness userAccessBusiness) { _readRepository = readRepository; _userAccessBusiness = userAccessBusiness; }
public VersionBusiness(IRepository repository, IReadRepository readRepository, IUserAccessBusiness userAccessBusiness) { _repository = repository; _readRepository = readRepository; _userAccessBusiness = userAccessBusiness; }
public UserAccessBusiness(IReadRepository readRepository) { _readRepository = readRepository; }
public DashboardBusiness(IRepository repository, IReadRepository readRepository) { _repository = repository; _readRepository = readRepository; }
public CustomerDetailsOverviewViewModel(IReadRepository readRepository) { _readRepository = readRepository; }
public CustomerListViewModel(IReadRepository repository, IEventAggregator eventAggregator) { _repository = repository; _eventAggregator = eventAggregator; }
public CourseController(IReadRepository repository, ICommandService commandService) { _repository = repository; _commandService = commandService; }