当前位置: 首页>>代码示例>>C#>>正文


C# IFlagCollection类代码示例

本文整理汇总了C#中IFlagCollection的典型用法代码示例。如果您正苦于以下问题:C# IFlagCollection类的具体用法?C# IFlagCollection怎么用?C# IFlagCollection使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


IFlagCollection类属于命名空间,在下文中一共展示了IFlagCollection类的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: BeginUidSetFlagsSilent

 public IAsyncResult BeginUidSetFlagsSilent(int uid, IFlagCollection flags, AsyncCallback callback)
 {
     this._delegateUidSetFlagsSilent = this.UidSetFlagsSilent;
     return this._delegateUidSetFlagsSilent.BeginInvoke(uid, flags, callback, this._delegateUidSetFlagsSilent);
 }
开发者ID:Inzaghi2012,项目名称:teamlab.v7.5,代码行数:5,代码来源:Mailbox.cs

示例2: UidAddFlagsSilent

 public void UidAddFlagsSilent(int uid, IFlagCollection flags)
 {
     this.SourceClient.Command("uid store " + uid.ToString() + " +flags.silent " + ((FlagCollection)flags).Merged);
 }
开发者ID:Inzaghi2012,项目名称:teamlab.v7.5,代码行数:4,代码来源:Mailbox.cs

示例3: BeginSetFlagsSilent

 public IAsyncResult BeginSetFlagsSilent(int messageOrdinal, IFlagCollection flags, AsyncCallback callback)
 {
     this._delegateSetFlagsSilent = this.SetFlagsSilent;
     return this._delegateSetFlagsSilent.BeginInvoke(messageOrdinal, flags, callback, this._delegateSetFlagsSilent);
 }
开发者ID:Inzaghi2012,项目名称:teamlab.v7.5,代码行数:5,代码来源:Mailbox.cs

示例4: SetFlags

 /// <summary>
 /// Sets the specified flags for the message.
 /// </summary>
 /// <param name="messageOrdinal">The message's ordinal position.</param>
 /// <param name="flags">Flags to be stored for the message.</param>
 /// <returns>The server's response.</returns>
 /// <example>
 /// <code>
 /// C#
 ///  
 /// Imap4Client imap = new Imap4Client();
 /// imap.Connect("mail.myhost.com");
 /// imap.Login("jdoe1234","tanstaaf");
 /// Mailbox inbox = imap.SelectInbox("inbox");
 /// FlagCollection flags = new FlagCollection();
 /// flags.Add("Read");
 /// flags.Add("Answered");
 /// inbox.AddFlags(1,flags);
 /// //Message is marked as read and answered. All prior flags are unset.
 /// imap.Disconnect();
 /// 
 /// VB.NET
 ///  
 /// Dim imap As New Imap4Client
 /// imap.Connect("mail.myhost.com")
 /// imap.Login("jdoe1234","tanstaaf")
 /// Dim inbox As Mailbox = imap.SelectInbox("inbox")
 /// Dim flags As New FlagCollection
 /// flags.Add("Read")
 /// flags.Add("Answered")
 /// inbox.AddFlags(1,flags)
 /// 'Message is marked as read and answered. All prior flags are unset.
 /// imap.Disconnect()
 /// 
 /// JScript.NET
 ///  
 /// var imap:Imap4Client imap = new Imap4Client();
 /// imap.Connect("mail.myhost.com");
 /// imap.Login("jdoe1234","tanstaaf");
 /// var inbox:Mailbox = imap.SelectInbox("inbox");
 /// var flags:FlagCollection = new FlagCollection();
 /// flags.Add("Read");
 /// flags.Add("Answered");
 /// inbox.AddFlags(1,flags);
 /// //Message is marked as read and answered. All prior flags are unset.
 /// imap.Disconnect();
 /// </code>
 /// </example>
 public string SetFlags(int messageOrdinal, IFlagCollection flags)
 {
     return this.SourceClient.Command("store " + messageOrdinal.ToString() + " flags " + ((FlagCollection)flags).Merged);
 }
开发者ID:Inzaghi2012,项目名称:teamlab.v7.5,代码行数:52,代码来源:Mailbox.cs

示例5: AddFlagsSilent

 /// <summary>
 /// Same as AddFlags() except no response is requested.
 /// </summary>
 /// <param name="messageOrdinal">The message's ordinal position.</param>
 /// <param name="flags">Flags to be added to the message.</param>
 /// <example><see cref="Mailbox.AddFlags"/></example>
 public void AddFlagsSilent(int messageOrdinal, IFlagCollection flags)
 {
     this.SourceClient.Command("store " + messageOrdinal.ToString() + " +flags.silent " + ((FlagCollection)flags).Merged);
 }
开发者ID:Inzaghi2012,项目名称:teamlab.v7.5,代码行数:10,代码来源:Mailbox.cs

示例6: BeginRemoveFlags

 public IAsyncResult BeginRemoveFlags(int messageOrdinal, IFlagCollection flags, AsyncCallback callback)
 {
     this._delegateRemoveFlags = this.RemoveFlags;
     return this._delegateRemoveFlags.BeginInvoke(messageOrdinal, flags, callback, this._delegateRemoveFlags);
 }
开发者ID:Inzaghi2012,项目名称:teamlab.v7.5,代码行数:5,代码来源:Mailbox.cs

示例7: BeginUidRemoveFlags

 public IAsyncResult BeginUidRemoveFlags(int uid, IFlagCollection flags, AsyncCallback callback)
 {
     this._delegateUidRemoveFlags = this.UidRemoveFlags;
     return this._delegateUidRemoveFlags.BeginInvoke(uid, flags, callback, this._delegateUidRemoveFlags);
 }
开发者ID:Inzaghi2012,项目名称:teamlab.v7.5,代码行数:5,代码来源:Mailbox.cs

示例8: BeginAppend

 public IAsyncResult BeginAppend(byte[] messageData, IFlagCollection flags, DateTime dateTime, AsyncCallback callback)
 {
     this._delegateAppendByteFlagsDateTime = this.Append;
     return this._delegateAppendByteFlagsDateTime.BeginInvoke(messageData, flags, dateTime, callback, this._delegateAppendByteFlagsDateTime);
 }
开发者ID:Inzaghi2012,项目名称:teamlab.v7.5,代码行数:5,代码来源:Mailbox.cs

示例9: UidAddFlags

 public string UidAddFlags(int uid, IFlagCollection flags)
 {
     return this.SourceClient.Command("uid store " + uid.ToString() + " +flags " + ((FlagCollection)flags).Merged);
 }
开发者ID:Inzaghi2012,项目名称:teamlab.v7.5,代码行数:4,代码来源:Mailbox.cs

示例10: Append

 /// <summary>
 /// Appends the provided message to the mailbox.
 /// </summary>
 /// <param name="message">The message to be appended.</param>
 /// <param name="flags">Flags to be set for the message.</param>
 /// <param name="dateTime">The internal date to be set for the message.</param>
 /// <example>
 /// <code>
 /// C#
 ///  
 /// Message message = new Message();
 /// message.From = new Address("[email protected]","John Doe");
 /// message.To.Add("[email protected]","Mike Johns");
 /// message.Subject = "hey!";
 /// message.Attachments.Add("C:\\myfile.doc");
 /// message.HtmlBody.Text = "As promised, the requested document.&lt;br />&lt;br />Regards,&lt;br>John.";
 /// 
 /// FlagCollection flags = new FlagCollection();
 /// flags.Add("Read");
 /// 
 /// Imap4Client imap = new Imap4Client();
 /// Mailbox inbox = imap.SelectMailbox("Read Messages");
 /// inbox.Append(message,flags,System.DateTime.Now);
 /// imap.Disconnect();
 ///  
 /// VB.NET
 ///  
 /// Dim message As New Message
 /// message.From = new Address("[email protected]","John Doe")
 /// message.To.Add("[email protected]","Mike Johns")
 /// message.Subject = "hey!"
 /// message.Attachments.Add("C:\myfile.doc")
 /// message.HtmlBody.Text = "As promised, the requested document.&lt;br />&lt;br />Regards,&lt;br>John."
 /// 
 /// Dim flags As New FlagCollection
 /// flags.Add("Read")
 ///  
 /// Dim imap As New Imap4Client
 /// Dim inbox As Mailbox = imap.SelectMailbox("Read Messages")
 /// inbox.Append(message,flags,System.DateTime.Now)
 /// imap.Disconnect()
 ///   
 /// JScript.NET
 ///  
 /// var message:Message = new Message();
 /// message.From = new Address("[email protected]","John Doe")
 /// message.To.Add("[email protected]","Mike Johns");
 /// message.Subject = "hey!";
 /// message.Attachments.Add("C:\\myfile.doc");
 /// message.HtmlBody.Text = "As promised, the requested document.&lt;br />&lt;br />Regards,&lt;br>John."
 /// 
 /// var flags:FlagCollection = new FlagCollection();
 /// flags.Add("Read");
 ///  
 /// var imap:Imap4Client = new Imap4Client();
 /// var inbox:Mailbox = imap.SelectMailbox("Read Messages");
 /// inbox.Append(message,flags,System.DateTime.Now);
 /// imap.Disconnect();
 /// </code>
 /// </example>
 public string Append(Message message, IFlagCollection flags, DateTime dateTime)
 {
     return this.Append(message.ToMimeString(),flags,dateTime);
 }
开发者ID:Inzaghi2012,项目名称:teamlab.v7.5,代码行数:64,代码来源:Mailbox.cs

示例11: Append

		/// <summary>
		/// Appends the provided message to the mailbox.
		/// </summary>
		/// <param name="messageData">The message in a Rfc822 compliant format.</param>
		/// <param name="flags">Flags to be set for the message.</param>
		/// <example><see cref="Mailbox.Append"/></example>
        public string Append(byte[] messageData, IFlagCollection flags)
		{
			return this.Append(System.Text.Encoding.ASCII.GetString(messageData,0,messageData.Length),flags);
		}
开发者ID:haoasqui,项目名称:MailSystem.NET,代码行数:10,代码来源:Mailbox.cs

示例12: Append

        /// <summary>
        /// Appends the provided message to the mailbox.
        /// </summary>
        /// <param name="messageLiteral">The message in a Rfc822 compliant format.</param>
        /// <param name="flags">Flags to be set for the message.</param>
        /// <param name="dateTime">The internal date to be set for the message.</param>
        public string Append(string messageLiteral, IFlagCollection flags, DateTime dateTime)
        {
            string firststamp = System.DateTime.Now.ToString("yyMMddhhmmss" + System.DateTime.Now.Millisecond.ToString());

            // FIX by Hannes Sachsenhofer for Imapsy
            // Office365 did not like the non-standard date-format, so I changed it to the standard format
            var d = dateTime.ToUniversalTime().ToString("dd-MMM-yyyy hh:mm:ss +0000", CultureInfo.InvariantCulture);

            this.SourceClient.Command("APPEND \"" + this.Name + "\" " + ((FlagCollection)flags).Merged + " \"" + d + "\" {" + (messageLiteral.Length) + "}", firststamp);
            return this.SourceClient.Command(messageLiteral, "", firststamp);
        }
开发者ID:saxx,项目名称:Imapsy,代码行数:17,代码来源:Mailbox.cs


注:本文中的IFlagCollection类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。