PrincipalOperationException 构造函数

定义

实例化 PrincipalOperationException 类的新实例。Instantiates a new instance of the PrincipalOperationException class.

重载

PrincipalOperationException()

实例化 PrincipalOperationException 类的新实例。Instantiates a new instance of the PrincipalOperationException class.

PrincipalOperationException(String)

用指定的错误消息实例化 PrincipalOperationException 类的新实例。Instantiates a new instance of the PrincipalOperationException class with the specified error message.

PrincipalOperationException(SerializationInfo, StreamingContext)

根据指定的 SerializationInfoStreamingContext 实例初始化 PrincipalOperationException 类的新实例。Initializes a new instance of the PrincipalOperationException class from the specified SerializationInfo and StreamingContext instances.

PrincipalOperationException(String, Exception)

使用指定的错误消息和指定的嵌套异常实例化 PrincipalOperationException 类的新实例。Instantiates a new instance of the PrincipalOperationException class with the specified error message and specified nested exception.

PrincipalOperationException(String, Int32)

使用指定的错误消息和指定的错误代码实例化 PrincipalOperationException 类的新实例。Instantiates a new instance of the PrincipalOperationException class with the specified error message and specified error code.

PrincipalOperationException(String, Exception, Int32)

使用指定的错误消息、指定的嵌套异常和指定的错误代码实例化 PrincipalOperationException 类的新实例。Instantiates a new instance of the PrincipalOperationException class with the specified error message, the specified nested exception, and the specified error code.

PrincipalOperationException()

实例化 PrincipalOperationException 类的新实例。Instantiates a new instance of the PrincipalOperationException class.

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

注解

无参数构造函数初始化PrincipalOperationException类的新实例。The parameterless constructor initializes a new instance of the PrincipalOperationException class. Message属性初始化为系统提供的描述错误的消息。The Message property is initialized to a system-supplied message that describes the error. 此消息将当前系统区域性考虑在内。This message takes into account the current system culture. InnerException 属性初始化为 nullThe InnerException property is initialized to null.

PrincipalOperationException(String)

用指定的错误消息实例化 PrincipalOperationException 类的新实例。Instantiates a new instance of the PrincipalOperationException class with the specified error message.

public:
 PrincipalOperationException(System::String ^ message);
public PrincipalOperationException (string message);
new System.DirectoryServices.AccountManagement.PrincipalOperationException : string -> System.DirectoryServices.AccountManagement.PrincipalOperationException
Public Sub New (message As String)

参数

message
String

错误消息的文本。The text of the error message.

注解

初始化实例, Message并将属性设置为的message值。 PrincipalOperationExceptionThe PrincipalOperationException instance is initialized with the Message property set to the value of message. 如果message Messagenull, 则将属性初始化为系统提供的消息。If message is null, the Message property is initialized to a system-supplied message.

PrincipalOperationException(SerializationInfo, StreamingContext)

根据指定的 SerializationInfoStreamingContext 实例初始化 PrincipalOperationException 类的新实例。Initializes a new instance of the PrincipalOperationException class from the specified SerializationInfo and StreamingContext instances.

protected:
 PrincipalOperationException(System::Runtime::Serialization::SerializationInfo ^ info, System::Runtime::Serialization::StreamingContext context);
protected PrincipalOperationException (System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context);
new System.DirectoryServices.AccountManagement.PrincipalOperationException : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> System.DirectoryServices.AccountManagement.PrincipalOperationException
Protected Sub New (info As SerializationInfo, context As StreamingContext)

参数

info
SerializationInfo

一个 SerializationInfo,其中包含序列化新的 PrincipalOperationException 所需的信息A SerializationInfo that contains the information required to serialize the new PrincipalOperationException

context
StreamingContext

一个 StreamingContext,其中包含与新的 PrincipalOperationException 关联的序列化流的源A StreamingContext that contains the source of the serialized stream that is associated with the new PrincipalOperationException

PrincipalOperationException(String, Exception)

使用指定的错误消息和指定的嵌套异常实例化 PrincipalOperationException 类的新实例。Instantiates a new instance of the PrincipalOperationException class with the specified error message and specified nested exception.

public:
 PrincipalOperationException(System::String ^ message, Exception ^ innerException);
public PrincipalOperationException (string message, Exception innerException);
new System.DirectoryServices.AccountManagement.PrincipalOperationException : string * Exception -> System.DirectoryServices.AccountManagement.PrincipalOperationException
Public Sub New (message As String, innerException As Exception)

参数

message
String

错误消息的文本。The text of the error message.

innerException
Exception

嵌套异常。A nested exception.

注解

message InnerException初始化PrincipalOperationException 实例,innerException并将属性设置为的值, 并将属性设置为的值。 MessageThe PrincipalOperationException instance is initialized with the Message property set to the value of message and the InnerException property set to the value of innerException. 如果message Messagenull, 则将属性初始化为系统提供的消息。If message is null, the Message property is initialized to a system-supplied message. 将初始化为nullInnerExceptionThe InnerException is initialized to null.

PrincipalOperationException(String, Int32)

使用指定的错误消息和指定的错误代码实例化 PrincipalOperationException 类的新实例。Instantiates a new instance of the PrincipalOperationException class with the specified error message and specified error code.

public:
 PrincipalOperationException(System::String ^ message, int errorCode);
public PrincipalOperationException (string message, int errorCode);
new System.DirectoryServices.AccountManagement.PrincipalOperationException : string * int -> System.DirectoryServices.AccountManagement.PrincipalOperationException
Public Sub New (message As String, errorCode As Integer)

参数

message
String

消息的文本。The text of the message.

errorCode
Int32

错误代码。An error code.

注解

message ErrorCode初始化PrincipalOperationException 实例,errorCode并将属性设置为的值, 并将属性设置为的值。 MessageThe PrincipalOperationException instance is initialized with the Message property set to the value of message and the ErrorCode property set to the value of errorCode. 如果message Messagenull, 则将属性初始化为系统提供的消息。If message is null, the Message property is initialized to a system-supplied message.

PrincipalOperationException(String, Exception, Int32)

使用指定的错误消息、指定的嵌套异常和指定的错误代码实例化 PrincipalOperationException 类的新实例。Instantiates a new instance of the PrincipalOperationException class with the specified error message, the specified nested exception, and the specified error code.

public:
 PrincipalOperationException(System::String ^ message, Exception ^ innerException, int errorCode);
public PrincipalOperationException (string message, Exception innerException, int errorCode);
new System.DirectoryServices.AccountManagement.PrincipalOperationException : string * Exception * int -> System.DirectoryServices.AccountManagement.PrincipalOperationException
Public Sub New (message As String, innerException As Exception, errorCode As Integer)

参数

message
String

消息的文本。The text of the message.

innerException
Exception

嵌套异常。A nested exception.

errorCode
Int32

错误代码。An error code.

注解

message InnerException ErrorCode innerException errorCode初始化PrincipalOperationException 实例,并将属性设置为的值,并将属性设置为的值,并将设置为。MessageThe PrincipalOperationException instance is initialized with the Message property set to the value of message and the InnerException property set to the value of innerException, and the ErrorCode is set to errorCode. 如果message Messagenull, 则将属性初始化为系统提供的消息。If message is null, the Message property is initialized to a system-supplied message. 将初始化为nullInnerExceptionThe InnerException is initialized to null.

适用于