共用方式為


ContractFailedEventArgs 建構函式

定義

提供 ContractFailed 事件的資料。

public:
 ContractFailedEventArgs(System::Diagnostics::Contracts::ContractFailureKind failureKind, System::String ^ message, System::String ^ condition, Exception ^ originalException);
public ContractFailedEventArgs (System.Diagnostics.Contracts.ContractFailureKind failureKind, string message, string condition, Exception originalException);
public ContractFailedEventArgs (System.Diagnostics.Contracts.ContractFailureKind failureKind, string? message, string? condition, Exception? originalException);
new System.Diagnostics.Contracts.ContractFailedEventArgs : System.Diagnostics.Contracts.ContractFailureKind * string * string * Exception -> System.Diagnostics.Contracts.ContractFailedEventArgs
Public Sub New (failureKind As ContractFailureKind, message As String, condition As String, originalException As Exception)

參數

failureKind
ContractFailureKind

一個列舉值,指定失敗的合約。

message
String

事件的訊息。

condition
String

事件的條件。

originalException
Exception

造成事件的例外狀況。

適用於