/// <summary> /// Generate notification messages (if any) for this source message /// </summary> /// <param name="envelope"></param> /// <param name="senders">sending acks on behalf of these message recipients</param> /// <param name="notificationType">processed or dispatched</param> /// <returns>An enumeration of messages</returns> public IEnumerable <NotificationMessage> Produce(IncomingMessage envelope, IEnumerable <MailAddress> senders, MDNStandard.NotificationType notificationType) { if (envelope == null) { throw new ArgumentNullException("envelope"); } if (senders != null && m_settings.AutoResponse) { IEnumerable <NotificationMessage> notifications = envelope.CreateAcks(senders, m_settings.ProductName, m_settings.Text, m_settings.AlwaysAck, notificationType); if (notifications != null) { foreach (NotificationMessage notification in notifications) { yield return(notification); } } } }