C# Class MailKit.MailTransport

An abstract mail transport implementation.
An abstract mail transport implementation.
Inheritance: MailService, IMailTransport
Afficher le fichier Open project: jstedfast/MailKit

Méthodes publiques

Méthode Description
Send ( MimeKit.FormatOptions options, MimeMessage message, CancellationToken cancellationToken = default(CancellationToken), ITransferProgress progress = null ) : void

Sends the specified message.

Sends the specified message.

The sender address is determined by checking the following message headers (in order of precedence): Resent-Sender, Resent-From, Sender, and From.

If either the Resent-Sender or Resent-From addresses are present, the recipients are collected from the Resent-To, Resent-Cc, and Resent-Bcc headers, otherwise the To, Cc, and Bcc headers are used.

Send ( MimeKit.FormatOptions options, MimeMessage message, MimeKit.MailboxAddress sender, IEnumerable recipients, CancellationToken cancellationToken = default(CancellationToken), ITransferProgress progress = null ) : void

Sends the specified message using the supplied sender and recipients.

Sends the specified message using the supplied sender and recipients.

Send ( MimeMessage message, CancellationToken cancellationToken = default(CancellationToken), ITransferProgress progress = null ) : void

Sends the specified message.

Sends the specified message.

The sender address is determined by checking the following message headers (in order of precedence): Resent-Sender, Resent-From, Sender, and From.

If either the Resent-Sender or Resent-From addresses are present, the recipients are collected from the Resent-To, Resent-Cc, and Resent-Bcc headers, otherwise the To, Cc, and Bcc headers are used.

Send ( MimeMessage message, MimeKit.MailboxAddress sender, IEnumerable recipients, CancellationToken cancellationToken = default(CancellationToken), ITransferProgress progress = null ) : void

Sends the specified message using the supplied sender and recipients.

Sends the specified message using the supplied sender and recipients.

SendAsync ( MimeKit.FormatOptions options, MimeMessage message, CancellationToken cancellationToken = default(CancellationToken), ITransferProgress progress = null ) : Task

Asynchronously sends the specified message.

Asynchronously sends the specified message.

The sender address is determined by checking the following message headers (in order of precedence): Resent-Sender, Resent-From, Sender, and From.

If either the Resent-Sender or Resent-From addresses are present, the recipients are collected from the Resent-To, Resent-Cc, and Resent-Bcc headers, otherwise the To, Cc, and Bcc headers are used.

SendAsync ( MimeKit.FormatOptions options, MimeMessage message, MimeKit.MailboxAddress sender, IEnumerable recipients, CancellationToken cancellationToken = default(CancellationToken), ITransferProgress progress = null ) : Task

Asynchronously sends the specified message using the supplied sender and recipients.

Asynchronously sends the specified message using the supplied sender and recipients.

SendAsync ( MimeMessage message, CancellationToken cancellationToken = default(CancellationToken), ITransferProgress progress = null ) : Task

Asynchronously sends the specified message.

Asynchronously sends the specified message.

The sender address is determined by checking the following message headers (in order of precedence): Resent-Sender, Resent-From, Sender, and From.

If either the Resent-Sender or Resent-From addresses are present, the recipients are collected from the Resent-To, Resent-Cc, and Resent-Bcc headers, otherwise the To, Cc, and Bcc headers are used.

SendAsync ( MimeMessage message, MimeKit.MailboxAddress sender, IEnumerable recipients, CancellationToken cancellationToken = default(CancellationToken), ITransferProgress progress = null ) : Task

Asynchronously sends the specified message using the supplied sender and recipients.

Asynchronously sends the specified message using the supplied sender and recipients.

Méthodes protégées

Méthode Description
MailTransport ( IProtocolLogger protocolLogger ) : System

Initializes a new instance of the MailKit.MailTransport class.

Initializes a new instance of the MailKit.MailTransport class.

OnMessageSent ( MessageSentEventArgs e ) : void

Raise the message sent event.

Raises the message sent event.

Method Details

MailTransport() protected méthode

Initializes a new instance of the MailKit.MailTransport class.
Initializes a new instance of the MailKit.MailTransport class.
/// is null. ///
protected MailTransport ( IProtocolLogger protocolLogger ) : System
protocolLogger IProtocolLogger The protocol logger.
Résultat System

OnMessageSent() protected méthode

Raise the message sent event.
Raises the message sent event.
protected OnMessageSent ( MessageSentEventArgs e ) : void
e MessageSentEventArgs The message sent event args.
Résultat void

Send() public abstract méthode

Sends the specified message.

Sends the specified message.

The sender address is determined by checking the following message headers (in order of precedence): Resent-Sender, Resent-From, Sender, and From.

If either the Resent-Sender or Resent-From addresses are present, the recipients are collected from the Resent-To, Resent-Cc, and Resent-Bcc headers, otherwise the To, Cc, and Bcc headers are used.

/// is null. /// -or- /// is null. /// /// The has been disposed. /// /// The is not connected. /// /// Authentication is required before sending a message. /// /// A sender has not been specified. /// -or- /// No recipients have been specified. /// /// The operation has been canceled. /// /// Internationalized formatting was requested but is not supported by the transport. /// /// An I/O error occurred. /// /// The send command failed. /// /// A protocol exception occurred. ///
public abstract Send ( MimeKit.FormatOptions options, MimeMessage message, CancellationToken cancellationToken = default(CancellationToken), ITransferProgress progress = null ) : void
options MimeKit.FormatOptions The formatting options.
message MimeKit.MimeMessage The message.
cancellationToken System.Threading.CancellationToken The cancellation token.
progress ITransferProgress The progress reporting mechanism.
Résultat void

Send() public abstract méthode

Sends the specified message using the supplied sender and recipients.
Sends the specified message using the supplied sender and recipients.
/// is null. /// -or- /// is null. /// -or- /// is null. /// -or- /// is null. /// /// The has been disposed. /// /// The is not connected. /// /// Authentication is required before sending a message. /// /// A sender has not been specified. /// -or- /// No recipients have been specified. /// /// The operation has been canceled. /// /// Internationalized formatting was requested but is not supported by the transport. /// /// An I/O error occurred. /// /// The send command failed. /// /// A protocol exception occurred. ///
public abstract Send ( MimeKit.FormatOptions options, MimeMessage message, MimeKit.MailboxAddress sender, IEnumerable recipients, CancellationToken cancellationToken = default(CancellationToken), ITransferProgress progress = null ) : void
options MimeKit.FormatOptions The formatting options.
message MimeKit.MimeMessage The message.
sender MimeKit.MailboxAddress The mailbox address to use for sending the message.
recipients IEnumerable The mailbox addresses that should receive the message.
cancellationToken System.Threading.CancellationToken The cancellation token.
progress ITransferProgress The progress reporting mechanism.
Résultat void

Send() public méthode

Sends the specified message.

Sends the specified message.

The sender address is determined by checking the following message headers (in order of precedence): Resent-Sender, Resent-From, Sender, and From.

If either the Resent-Sender or Resent-From addresses are present, the recipients are collected from the Resent-To, Resent-Cc, and Resent-Bcc headers, otherwise the To, Cc, and Bcc headers are used.

/// is null. /// /// The has been disposed. /// /// The is not connected. /// /// Authentication is required before sending a message. /// /// A sender has not been specified. /// -or- /// No recipients have been specified. /// /// The operation has been canceled. /// /// An I/O error occurred. /// /// The send command failed. /// /// A protocol exception occurred. ///
public Send ( MimeMessage message, CancellationToken cancellationToken = default(CancellationToken), ITransferProgress progress = null ) : void
message MimeKit.MimeMessage The message.
cancellationToken System.Threading.CancellationToken The cancellation token.
progress ITransferProgress The progress reporting mechanism.
Résultat void

Send() public méthode

Sends the specified message using the supplied sender and recipients.
Sends the specified message using the supplied sender and recipients.
/// is null. /// -or- /// is null. /// -or- /// is null. /// /// The has been disposed. /// /// The is not connected. /// /// Authentication is required before sending a message. /// /// A sender has not been specified. /// -or- /// No recipients have been specified. /// /// The operation has been canceled. /// /// An I/O error occurred. /// /// The send command failed. /// /// A protocol exception occurred. ///
public Send ( MimeMessage message, MimeKit.MailboxAddress sender, IEnumerable recipients, CancellationToken cancellationToken = default(CancellationToken), ITransferProgress progress = null ) : void
message MimeKit.MimeMessage The message.
sender MimeKit.MailboxAddress The mailbox address to use for sending the message.
recipients IEnumerable The mailbox addresses that should receive the message.
cancellationToken System.Threading.CancellationToken The cancellation token.
progress ITransferProgress The progress reporting mechanism.
Résultat void

SendAsync() public méthode

Asynchronously sends the specified message.

Asynchronously sends the specified message.

The sender address is determined by checking the following message headers (in order of precedence): Resent-Sender, Resent-From, Sender, and From.

If either the Resent-Sender or Resent-From addresses are present, the recipients are collected from the Resent-To, Resent-Cc, and Resent-Bcc headers, otherwise the To, Cc, and Bcc headers are used.

/// is null. /// -or- /// is null. /// /// The has been disposed. /// /// The is not connected. /// /// Authentication is required before sending a message. /// /// A sender has not been specified. /// -or- /// No recipients have been specified. /// /// The operation has been canceled. /// /// Internationalized formatting was requested but is not supported by the transport. /// /// An I/O error occurred. /// /// The send command failed. /// /// A protocol exception occurred. ///
public SendAsync ( MimeKit.FormatOptions options, MimeMessage message, CancellationToken cancellationToken = default(CancellationToken), ITransferProgress progress = null ) : Task
options MimeKit.FormatOptions The formatting options.
message MimeKit.MimeMessage The message.
cancellationToken System.Threading.CancellationToken The cancellation token.
progress ITransferProgress The progress reporting mechanism.
Résultat Task

SendAsync() public méthode

Asynchronously sends the specified message using the supplied sender and recipients.
Asynchronously sends the specified message using the supplied sender and recipients.
/// is null. /// -or- /// is null. /// -or- /// is null. /// -or- /// is null. /// /// The has been disposed. /// /// The is not connected. /// /// Authentication is required before sending a message. /// /// A sender has not been specified. /// -or- /// No recipients have been specified. /// /// The operation has been canceled. /// /// Internationalized formatting was requested but is not supported by the transport. /// /// An I/O error occurred. /// /// The send command failed. /// /// A protocol exception occurred. ///
public SendAsync ( MimeKit.FormatOptions options, MimeMessage message, MimeKit.MailboxAddress sender, IEnumerable recipients, CancellationToken cancellationToken = default(CancellationToken), ITransferProgress progress = null ) : Task
options MimeKit.FormatOptions The formatting options.
message MimeKit.MimeMessage The message.
sender MimeKit.MailboxAddress The mailbox address to use for sending the message.
recipients IEnumerable The mailbox addresses that should receive the message.
cancellationToken System.Threading.CancellationToken The cancellation token.
progress ITransferProgress The progress reporting mechanism.
Résultat Task

SendAsync() public méthode

Asynchronously sends the specified message.

Asynchronously sends the specified message.

The sender address is determined by checking the following message headers (in order of precedence): Resent-Sender, Resent-From, Sender, and From.

If either the Resent-Sender or Resent-From addresses are present, the recipients are collected from the Resent-To, Resent-Cc, and Resent-Bcc headers, otherwise the To, Cc, and Bcc headers are used.

/// is null. /// /// The has been disposed. /// /// The is not connected. /// /// Authentication is required before sending a message. /// /// A sender has not been specified. /// -or- /// No recipients have been specified. /// /// The operation has been canceled. /// /// An I/O error occurred. /// /// The send command failed. /// /// A protocol exception occurred. ///
public SendAsync ( MimeMessage message, CancellationToken cancellationToken = default(CancellationToken), ITransferProgress progress = null ) : Task
message MimeKit.MimeMessage The message.
cancellationToken System.Threading.CancellationToken The cancellation token.
progress ITransferProgress The progress reporting mechanism.
Résultat Task

SendAsync() public méthode

Asynchronously sends the specified message using the supplied sender and recipients.
Asynchronously sends the specified message using the supplied sender and recipients.
/// is null. /// -or- /// is null. /// -or- /// is null. /// /// The has been disposed. /// /// The is not connected. /// /// Authentication is required before sending a message. /// /// A sender has not been specified. /// -or- /// No recipients have been specified. /// /// The operation has been canceled. /// /// An I/O error occurred. /// /// The send command failed. /// /// A protocol exception occurred. ///
public SendAsync ( MimeMessage message, MimeKit.MailboxAddress sender, IEnumerable recipients, CancellationToken cancellationToken = default(CancellationToken), ITransferProgress progress = null ) : Task
message MimeKit.MimeMessage The message.
sender MimeKit.MailboxAddress The mailbox address to use for sending the message.
recipients IEnumerable The mailbox addresses that should receive the message.
cancellationToken System.Threading.CancellationToken The cancellation token.
progress ITransferProgress The progress reporting mechanism.
Résultat Task