C# Класс MimeKit.MessagePart

A MIME part containing a MimeKit.MimeMessage as its content.
Represents MIME entities such as those with a Content-Type of message/rfc822 or message/news.
Наследование: MimeKit.MimeEntity
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
Accept ( MimeKit.MimeVisitor visitor ) : void

Dispatches to the specific visit method for this MIME entity.

This default implementation for MimeKit.MessagePart nodes calls MimeKit.MimeVisitor.VisitMessagePart. Override this method to call into a more specific method on a derived visitor class of the MimeKit.MimeVisitor class. However, it should still support unknown visitors by calling MimeKit.MimeVisitor.VisitMessagePart.

MessagePart ( ) : System

Initializes a new instance of the MimeKit.MessagePart class.

Creates a new message/rfc822 MIME entity.

MessagePart ( MimeKit.MimeEntityConstructorArgs args ) : System

Initializes a new instance of the MimeKit.MessagePart class.

This constructor is used by MimeKit.MimeParser.

MessagePart ( string subtype ) : System

Initializes a new instance of the MimeKit.MessagePart class.

Creates a new MessagePart.

Prepare ( EncodingConstraint constraint, int maxLineLength = 78 ) : void

Prepare the MIME entity for transport using the specified encoding constraints.

Prepares the MIME entity for transport using the specified encoding constraints.

WriteTo ( MimeKit.FormatOptions options, Stream stream, bool contentOnly, CancellationToken cancellationToken = default(CancellationToken) ) : void

Writes the MimeKit.MessagePart to the output stream.

Writes the MIME entity and its message to the output stream.

Описание методов

Accept() публичный Метод

Dispatches to the specific visit method for this MIME entity.
This default implementation for MimeKit.MessagePart nodes calls MimeKit.MimeVisitor.VisitMessagePart. Override this method to call into a more specific method on a derived visitor class of the MimeKit.MimeVisitor class. However, it should still support unknown visitors by calling MimeKit.MimeVisitor.VisitMessagePart.
/// is null. ///
public Accept ( MimeKit.MimeVisitor visitor ) : void
visitor MimeKit.MimeVisitor The visitor.
Результат void

MessagePart() публичный Метод

Initializes a new instance of the MimeKit.MessagePart class.
Creates a new message/rfc822 MIME entity.
public MessagePart ( ) : System
Результат System

MessagePart() публичный Метод

Initializes a new instance of the MimeKit.MessagePart class.
This constructor is used by MimeKit.MimeParser.
/// is null. ///
public MessagePart ( MimeKit.MimeEntityConstructorArgs args ) : System
args MimeKit.MimeEntityConstructorArgs Information used by the constructor.
Результат System

MessagePart() публичный Метод

Initializes a new instance of the MimeKit.MessagePart class.
Creates a new MessagePart.
/// is null. /// -or- /// is null. /// /// contains more than one . /// -or- /// contains one or more arguments of an unknown type. ///
public MessagePart ( string subtype ) : System
subtype string The message subtype.
Результат System

Prepare() публичный Метод

Prepare the MIME entity for transport using the specified encoding constraints.
Prepares the MIME entity for transport using the specified encoding constraints.
/// is not between 60 and 998 (inclusive). /// -or- /// is not a valid value. ///
public Prepare ( EncodingConstraint constraint, int maxLineLength = 78 ) : void
constraint EncodingConstraint The encoding constraint.
maxLineLength int The maximum number of octets allowed per line (not counting the CRLF). Must be between 60 and 998 (inclusive).
Результат void

WriteTo() публичный Метод

Writes the MimeKit.MessagePart to the output stream.
Writes the MIME entity and its message to the output stream.
/// is null. /// -or- /// is null. /// /// The operation was canceled via the cancellation token. /// /// An I/O error occurred. ///
public WriteTo ( MimeKit.FormatOptions options, Stream stream, bool contentOnly, CancellationToken cancellationToken = default(CancellationToken) ) : void
options MimeKit.FormatOptions The formatting options.
stream Stream The output stream.
contentOnly bool true if only the content should be written; otherwise, false.
cancellationToken System.Threading.CancellationToken A cancellation token.
Результат void