/// <summary> /// /// </summary> /// <param name="selectInvoiceService"></param> /// <param name="confidentialInvoiceWebService"></param> /// <param name="businessLoansService"></param> public ProductApplicationService(ISelectInvoiceService selectInvoiceService, IConfidentialInvoiceService confidentialInvoiceWebService, IBusinessLoansService businessLoansService) { ServicesMediator = new ServicesMediator(); ServicesMediator.Add(typeof(ISelectInvoiceService), selectInvoiceService); ServicesMediator.Add(typeof(IConfidentialInvoiceService), confidentialInvoiceWebService); ServicesMediator.Add(typeof(IBusinessLoansService), businessLoansService); }
/// <summary> /// /// </summary> /// <param name="servicesMediator"></param> /// <returns></returns> public IProductService GetProductService(IServicesMediator servicesMediator) { return(new ConfidentialInvoiceDiscountService(servicesMediator.Services[typeof(IConfidentialInvoiceService)] as IConfidentialInvoiceService, this)); }
/// <summary> /// /// </summary> /// <param name="servicesMediator"></param> /// <returns></returns> public IProductService GetProductService(IServicesMediator servicesMediator) { return(new BusinessLoanService(servicesMediator.Services[typeof(IBusinessLoansService)] as IBusinessLoansService, this)); }
/// <summary> /// /// </summary> /// <param name="servicesMediator"></param> /// <returns></returns> public IProductService GetProductService(IServicesMediator servicesMediator) { return(new SelectedInvoiceDiscountService(servicesMediator.Services[typeof(ISelectInvoiceService)] as ISelectInvoiceService, this)); }