You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

BusinessConfigurationExtension.cs 2.1KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. namespace Diligent.WebAPI.Host.Extensions
  2. {
  3. public static class BusinessConfigurationExtension
  4. {
  5. /// <summary>
  6. /// Services configuration
  7. /// </summary>
  8. public static void ConfigureBusiness(this WebApplicationBuilder builder)
  9. {
  10. IServiceCollection services = builder.Services;
  11. services.AddAutoMapper(typeof(CompanyMappingProfile));
  12. services.AddAutoMapper(typeof(WebhookMappingProfile));
  13. services.AddAutoMapper(typeof(InsurerMappingProfile));
  14. services.AddAutoMapper(typeof(ApplicantMappingProfile));
  15. services.AddAutoMapper(typeof(SelectionProcessMappingProfile));
  16. services.AddAutoMapper(typeof(SelectionLevelMappingProfile));
  17. services.AddScoped<IInsurersService, InsurersService>();
  18. services.AddScoped<IEmailer, Emailer>();
  19. services.AddScoped<IHttpClientService, HttpClientService>();
  20. services.AddScoped<IInsuranceCompaniesService, InsuranceCompaniesService>();
  21. services.AddScoped<ISelectionProcessService, SelectionProcessService>();
  22. services.AddScoped<ISelectionLevelService, SelectionLevelService>();
  23. services.AddScoped<IInsurancePoliciesService, InsurancePoliciesService>();
  24. services.AddScoped<IWebhookSubscriptionService, WebhookSubscriptionService>();
  25. services.AddScoped<IWebhookDefinitionService, WebhookDefinitionService>();
  26. services.AddScoped<IWebhookPublisherService, WebhookPublisherService>();
  27. services.AddScoped<IWebhookPublisherService, WebhookPublisherService>();
  28. services.AddScoped<IApplicantService, ApplicantService>();
  29. services.AddScoped<IAuthenticationService, AuthenticationService>();
  30. services.AddScoped<IAdService, AdService>();
  31. services.AddScoped<ITechnologyService, TechnologyService>();
  32. }
  33. /// <summary>
  34. /// App configuration
  35. /// </summary>
  36. public static void ConfigureBusiness(this WebApplication app)
  37. {
  38. //
  39. }
  40. }
  41. }