コード例 #1
0
ファイル: ImapAddress.cs プロジェクト: pengyancai/cs-util
        public static MailAddressCollection ToMailAddressCollection(ImapAddress[] addresses)
        {
            if (addresses == null)
            return null;

              var addressCollection = new MailAddressCollection();

              foreach (var address in addresses) {
            addressCollection.Add(address.ToMailAddress());
              }

              return addressCollection;
        }
コード例 #2
0
ファイル: ImapEnvelope.cs プロジェクト: pengyancai/cs-util
 public ImapEnvelope(string date,
                 string subject,
                 ImapAddress[] @from,
                 ImapAddress[] sender,
                 ImapAddress[] replyTo,
                 ImapAddress[] @to,
                 ImapAddress[] cc,
                 ImapAddress[] bcc,
                 string inReplyTo,
                 string messageId)
 {
     this.date       = date;
       this.subject    = subject;
       this.@from     = @from;
       this.sender     = sender;
       this.replyTo    = replyTo;
       this.@to        = @to;
       this.cc         = cc;
       this.bcc        = bcc;
       this.inReplyTo  = inReplyTo;
       this.messageId  = messageId;
 }