InvalidCredentialException 构造函数

定义

初始化 InvalidCredentialException 类的新实例。

重载

InvalidCredentialException()

不使用任何消息初始化 InvalidCredentialException 类的新实例。

InvalidCredentialException(String)

使用指定的消息初始化 InvalidCredentialException 类的新实例。

InvalidCredentialException(SerializationInfo, StreamingContext)
已过时.

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

InvalidCredentialException(String, Exception)

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

InvalidCredentialException()

Source:
AuthenticationException.cs
Source:
AuthenticationException.cs
Source:
AuthenticationException.cs

不使用任何消息初始化 InvalidCredentialException 类的新实例。

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

注解

此构造函数不执行任何工作。

适用于

InvalidCredentialException(String)

Source:
AuthenticationException.cs
Source:
AuthenticationException.cs
Source:
AuthenticationException.cs

使用指定的消息初始化 InvalidCredentialException 类的新实例。

public:
 InvalidCredentialException(System::String ^ message);
public InvalidCredentialException (string? message);
public InvalidCredentialException (string message);
new System.Security.Authentication.InvalidCredentialException : string -> System.Security.Authentication.InvalidCredentialException
Public Sub New (message As String)

参数

message
String

描述身份验证失败的 String

注解

此构造函数使用 参数中的message文本初始化 Message 属性。 将 InnerException 属性设置为 null

另请参阅

适用于

InvalidCredentialException(SerializationInfo, StreamingContext)

Source:
AuthenticationException.cs
Source:
AuthenticationException.cs
Source:
AuthenticationException.cs

注意

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

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

protected:
 InvalidCredentialException(System::Runtime::Serialization::SerializationInfo ^ serializationInfo, System::Runtime::Serialization::StreamingContext streamingContext);
protected InvalidCredentialException (System.Runtime.Serialization.SerializationInfo serializationInfo, System.Runtime.Serialization.StreamingContext streamingContext);
[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 InvalidCredentialException (System.Runtime.Serialization.SerializationInfo serializationInfo, System.Runtime.Serialization.StreamingContext streamingContext);
new System.Security.Authentication.InvalidCredentialException : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> System.Security.Authentication.InvalidCredentialException
[<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.Security.Authentication.InvalidCredentialException : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> System.Security.Authentication.InvalidCredentialException
Protected Sub New (serializationInfo As SerializationInfo, streamingContext As StreamingContext)

参数

serializationInfo
SerializationInfo

SerializationInfo 实例,包含反序列化新的 InvalidCredentialException 实例所需的信息。

streamingContext
StreamingContext

一个 StreamingContext 实例。

属性

另请参阅

适用于

InvalidCredentialException(String, Exception)

Source:
AuthenticationException.cs
Source:
AuthenticationException.cs
Source:
AuthenticationException.cs

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

public:
 InvalidCredentialException(System::String ^ message, Exception ^ innerException);
public InvalidCredentialException (string? message, Exception? innerException);
public InvalidCredentialException (string message, Exception innerException);
new System.Security.Authentication.InvalidCredentialException : string * Exception -> System.Security.Authentication.InvalidCredentialException
Public Sub New (message As String, innerException As Exception)

参数

message
String

描述身份验证失败的 String

innerException
Exception

导致当前异常的 Exception

注解

此构造函数使用 参数中的文本初始化 Message 属性,并使用innerException参数值初始化 InnerExceptionmessage 属性。

另请参阅

适用于