Esempio n. 1
0
 public MailSatellite(FindAttachments findAttachments, CleanAttachments cleanAttachments, BuildSmtpClient buildSmtpClient, IMessageSerializer serializer)
 {
     this.findAttachments  = findAttachments;
     this.cleanAttachments = cleanAttachments;
     this.buildSmtpClient  = buildSmtpClient;
     this.serializer       = serializer;
 }
Esempio n. 2
0
        /// <summary>
        /// Register attachment discovery and cleanup.
        /// </summary>
        public void UseAttachmentFinder(
            FindAttachments findAttachments,
            CleanAttachments cleanAttachments)
        {
            Guard.AgainstNull(nameof(findAttachments), findAttachments);
            Guard.AgainstNull(nameof(cleanAttachments), cleanAttachments);
            var settings = config.GetSettings();

            settings.Set <FindAttachments>(findAttachments);
            settings.Set <CleanAttachments>(cleanAttachments);
        }