/// <summary> /// Constructs the service. /// </summary> /// <param name="settings">An instance of <see cref="EmailServiceSettings"/> used to initialize the service.</param> /// <param name="viewEngine">Represents an <see cref="IViewEngine"/> that delegates to one of a collection of view engines.</param> /// <param name="tempDataProvider">Defines the contract for temporary-data providers that store data that is viewed on the next request.</param> /// <param name="httpContextAccessor">Used to access the <see cref="HttpContext"/> through the <see cref="IHttpContextAccessor"/> interface and its default implementation <see cref="HttpContextAccessor"/>.</param> /// <param name="serviceProvider">Defines a mechanism for retrieving a service object; that is, an object that provides custom support to other objects.</param> public EmailServiceSmtpRazor( EmailServiceSettings settings, ICompositeViewEngine viewEngine, ITempDataProvider tempDataProvider, IHttpContextAccessor httpContextAccessor, IServiceProvider serviceProvider ) : base(viewEngine, tempDataProvider, httpContextAccessor, serviceProvider) => _settings = settings ?? throw new ArgumentNullException(nameof(settings));
/// <summary> /// Cconstructs the service. /// </summary> /// <param name="settings">The SMTP settings to use.</param> public EmailServiceSmtp(EmailServiceSettings settings) => _settings = settings ?? throw new ArgumentNullException(nameof(settings));