public EmailWatcher(IEmailPackageSerialiser packageSerialiser, EmailProcessingConfigurationSection emailProcessingConfiguration) { _packageSerialiser = packageSerialiser; _emailProcessingConfiguration = emailProcessingConfiguration; _watchLocation = _emailProcessingConfiguration.PickupLocation; _failedLocation = _emailProcessingConfiguration.FailedLocation; _deliveredLocation = _emailProcessingConfiguration.DeliveredLocation; }
public AmazonSESEmailSender(EmailProcessingConfigurationSection configuration) : base(configuration) { _configuration = configuration; using (var ses = Amazon.AWSClientFactory.CreateAmazonSimpleEmailServiceClient( configuration.Amazon.Key, configuration.Amazon.Secret)) { var response = ses.GetSendQuota(new GetSendQuotaRequest()); _maxSendRate = response.GetSendQuotaResult.MaxSendRate; logger.InfoFormat("Amazon SES max send rate is {0:#.#} emails per second", _maxSendRate); } }
public void VerifyEmail(string email) { _configuration = ConfigurationManager.GetSection("emailProcessing") as EmailProcessingConfigurationSection; AmazonSESEmailSender aSes = new AmazonSESEmailSender(_configuration); aSes.VerifyEmail(email); }
public static IEmailSender CreateSenderFromConfiguration(EmailProcessingConfigurationSection configuration) { IEmailSender sender = Activator.CreateInstance(Type.GetType(configuration.EmailSenderType), configuration) as IEmailSender; return sender; }
public EmailSender(EmailProcessingConfigurationSection configuration) { DeliveredLocation = configuration.DeliveredLocation; FailedLocation = configuration.FailedLocation; }