Пример #1
0
 public CompanyService(
     ICompanyRepository companyRepository,
     IMapper mapper,
     IBillingCardService billingCardService,
     IBillingCustomerService billingCustomerService,
     IBillingChargeService billingChargeService)
 {
     _companyRepository = companyRepository;
     _mapper = mapper;
     _billingCardService = billingCardService;
     _billingCustomerService = billingCustomerService;
     _billingChargeService = billingChargeService;
 }
Пример #2
0
 public CompanyService(
     ICompanyRepository companyRepository,
     IMapper mapper,
     IBillingCardService billingCardService,
     IBillingCustomerService billingCustomerService,
     IBillingChargeService billingChargeService)
 {
     _companyRepository      = companyRepository;
     _mapper                 = mapper;
     _billingCardService     = billingCardService;
     _billingCustomerService = billingCustomerService;
     _billingChargeService   = billingChargeService;
 }
Пример #3
0
        public BillingEventHandler(
            IBillingEventService billingEventService,
            IBalanceService balanceService,
            IBillingChargeService billingChargeService,
            IBillingEventLogService billingEventLogService,
            ICompanyService companyService,
            IEmailNotificationService notificationService)
        {
            _billingEventService = billingEventService;
            _balanceService = balanceService;
            _billingChargeService = billingChargeService;
            _billingEventLogService = billingEventLogService;
            _companyService = companyService;
            _notificationService = notificationService;

            _eventHandlers = new Dictionary<EventType, Func<DomainEvent, Task>>
            {
                { EventType.ChargeFailed, ChargeFailedAsync },
                { EventType.ChargeRefunded, ChargeRefundedAsync },
                { EventType.ChargeSucceeded, ChargeSucceededAsync },
            };
        }
Пример #4
0
        public BillingEventHandler(
            IBillingEventService billingEventService,
            IBalanceService balanceService,
            IBillingChargeService billingChargeService,
            IBillingEventLogService billingEventLogService,
            ICompanyService companyService,
            IEmailNotificationService notificationService)
        {
            _billingEventService    = billingEventService;
            _balanceService         = balanceService;
            _billingChargeService   = billingChargeService;
            _billingEventLogService = billingEventLogService;
            _companyService         = companyService;
            _notificationService    = notificationService;

            _eventHandlers = new Dictionary <EventType, Func <DomainEvent, Task> >
            {
                { EventType.ChargeFailed, ChargeFailedAsync },
                { EventType.ChargeRefunded, ChargeRefundedAsync },
                { EventType.ChargeSucceeded, ChargeSucceededAsync },
            };
        }