SmtpFailedRecipientException 构造函数

定义

初始化 SmtpFailedRecipientException 类的新实例。

重载

SmtpFailedRecipientException()

初始化 SmtpFailedRecipientException 类的空实例。

SmtpFailedRecipientException(String)

使用指定的错误消息初始化 SmtpFailedRecipientException 类的新实例。

SmtpFailedRecipientException(SmtpStatusCode, String)

用指定的状态代码和电子邮件地址初始化 SmtpFailedRecipientException 类的新实例。

SmtpFailedRecipientException(SerializationInfo, StreamingContext)
已过时.

SmtpFailedRecipientExceptionSerializationInfo 类的指定实例初始化 StreamingContext 类的新实例。

SmtpFailedRecipientException(String, Exception)

使用指定的错误消息和内部异常初始化 SmtpException 类的新实例。

SmtpFailedRecipientException(SmtpStatusCode, String, String)

用指定的状态代码、电子邮件地址和服务器响应初始化 SmtpFailedRecipientException 类的新实例。

SmtpFailedRecipientException(String, String, Exception)

用指定的错误信息、电子邮件地址和内部异常初始化 SmtpException 类的新实例。

SmtpFailedRecipientException()

Source:
SmtpFailedRecipientException.cs
Source:
SmtpFailedRecipientException.cs
Source:
SmtpFailedRecipientException.cs

初始化 SmtpFailedRecipientException 类的空实例。

public:
 SmtpFailedRecipientException();
public SmtpFailedRecipientException ();
Public Sub New ()

适用于

SmtpFailedRecipientException(String)

Source:
SmtpFailedRecipientException.cs
Source:
SmtpFailedRecipientException.cs
Source:
SmtpFailedRecipientException.cs

使用指定的错误消息初始化 SmtpFailedRecipientException 类的新实例。

public:
 SmtpFailedRecipientException(System::String ^ message);
public SmtpFailedRecipientException (string? message);
public SmtpFailedRecipientException (string message);
new System.Net.Mail.SmtpFailedRecipientException : string -> System.Net.Mail.SmtpFailedRecipientException
Public Sub New (message As String)

参数

message
String

包含错误消息的 String

注解

此构造函数使用 message 参数初始化 Message 属性。

适用于

SmtpFailedRecipientException(SmtpStatusCode, String)

Source:
SmtpFailedRecipientException.cs
Source:
SmtpFailedRecipientException.cs
Source:
SmtpFailedRecipientException.cs

用指定的状态代码和电子邮件地址初始化 SmtpFailedRecipientException 类的新实例。

public:
 SmtpFailedRecipientException(System::Net::Mail::SmtpStatusCode statusCode, System::String ^ failedRecipient);
public SmtpFailedRecipientException (System.Net.Mail.SmtpStatusCode statusCode, string? failedRecipient);
public SmtpFailedRecipientException (System.Net.Mail.SmtpStatusCode statusCode, string failedRecipient);
new System.Net.Mail.SmtpFailedRecipientException : System.Net.Mail.SmtpStatusCode * string -> System.Net.Mail.SmtpFailedRecipientException
Public Sub New (statusCode As SmtpStatusCode, failedRecipient As String)

参数

statusCode
SmtpStatusCode

一个 SmtpStatusCode 值。

failedRecipient
String

包含电子邮件地址的 String

注解

此构造函数使用 statusCode 参数初始化 属性, StatusCode 并使用 failedRecipient 参数初始化 FailedRecipient 属性。

适用于

SmtpFailedRecipientException(SerializationInfo, StreamingContext)

Source:
SmtpFailedRecipientException.cs
Source:
SmtpFailedRecipientException.cs
Source:
SmtpFailedRecipientException.cs

注意

This API supports obsolete formatter-based serialization. It should not be called or extended by application code.

SmtpFailedRecipientExceptionSerializationInfo 类的指定实例初始化 StreamingContext 类的新实例。

protected:
 SmtpFailedRecipientException(System::Runtime::Serialization::SerializationInfo ^ info, System::Runtime::Serialization::StreamingContext context);
protected SmtpFailedRecipientException (System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context);
[System.Obsolete("This API supports obsolete formatter-based serialization. It should not be called or extended by application code.", DiagnosticId="SYSLIB0051", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
protected SmtpFailedRecipientException (System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context);
new System.Net.Mail.SmtpFailedRecipientException : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> System.Net.Mail.SmtpFailedRecipientException
[<System.Obsolete("This API supports obsolete formatter-based serialization. It should not be called or extended by application code.", DiagnosticId="SYSLIB0051", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
new System.Net.Mail.SmtpFailedRecipientException : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> System.Net.Mail.SmtpFailedRecipientException
Protected Sub New (info As SerializationInfo, context As StreamingContext)

参数

info
SerializationInfo

SerializationInfo,包含序列化新的 SmtpFailedRecipientException 所需的信息。

context
StreamingContext

StreamingContext,包含与新实例关联的序列化流的源和目标。

属性

注解

此构造函数实现 ISerializable 类的 SmtpFailedRecipientException 接口。

适用于

SmtpFailedRecipientException(String, Exception)

Source:
SmtpFailedRecipientException.cs
Source:
SmtpFailedRecipientException.cs
Source:
SmtpFailedRecipientException.cs

使用指定的错误消息和内部异常初始化 SmtpException 类的新实例。

public:
 SmtpFailedRecipientException(System::String ^ message, Exception ^ innerException);
public SmtpFailedRecipientException (string? message, Exception? innerException);
public SmtpFailedRecipientException (string message, Exception innerException);
new System.Net.Mail.SmtpFailedRecipientException : string * Exception -> System.Net.Mail.SmtpFailedRecipientException
Public Sub New (message As String, innerException As Exception)

参数

message
String

描述发生的错误的 String

innerException
Exception

导致当前异常的异常。

适用于

SmtpFailedRecipientException(SmtpStatusCode, String, String)

Source:
SmtpFailedRecipientException.cs
Source:
SmtpFailedRecipientException.cs
Source:
SmtpFailedRecipientException.cs

用指定的状态代码、电子邮件地址和服务器响应初始化 SmtpFailedRecipientException 类的新实例。

public:
 SmtpFailedRecipientException(System::Net::Mail::SmtpStatusCode statusCode, System::String ^ failedRecipient, System::String ^ serverResponse);
public SmtpFailedRecipientException (System.Net.Mail.SmtpStatusCode statusCode, string? failedRecipient, string? serverResponse);
public SmtpFailedRecipientException (System.Net.Mail.SmtpStatusCode statusCode, string failedRecipient, string serverResponse);
new System.Net.Mail.SmtpFailedRecipientException : System.Net.Mail.SmtpStatusCode * string * string -> System.Net.Mail.SmtpFailedRecipientException
Public Sub New (statusCode As SmtpStatusCode, failedRecipient As String, serverResponse As String)

参数

statusCode
SmtpStatusCode

一个 SmtpStatusCode 值。

failedRecipient
String

包含电子邮件地址的 String

serverResponse
String

包含服务器响应的 String

注解

此构造函数使用 statusCode 参数初始化 属性, StatusCode 并使用 failedRecipient 参数初始化 FailedRecipient 属性。

适用于

SmtpFailedRecipientException(String, String, Exception)

Source:
SmtpFailedRecipientException.cs
Source:
SmtpFailedRecipientException.cs
Source:
SmtpFailedRecipientException.cs

用指定的错误信息、电子邮件地址和内部异常初始化 SmtpException 类的新实例。

public:
 SmtpFailedRecipientException(System::String ^ message, System::String ^ failedRecipient, Exception ^ innerException);
public SmtpFailedRecipientException (string? message, string? failedRecipient, Exception? innerException);
public SmtpFailedRecipientException (string message, string failedRecipient, Exception innerException);
new System.Net.Mail.SmtpFailedRecipientException : string * string * Exception -> System.Net.Mail.SmtpFailedRecipientException
Public Sub New (message As String, failedRecipient As String, innerException As Exception)

参数

message
String

描述发生的错误的 String

failedRecipient
String

包含电子邮件地址的 String

innerException
Exception

导致当前异常的异常。

适用于