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 }, }; }
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 }, }; }