Provides methods and data for the Contract.ContractFailed event.
Assembly: mscorlib (in mscorlib.dll)
|ContractFailedEventArgs(ContractFailureKind, String, String, Exception)|
Provides data for the Contract.ContractFailed event.
Gets the condition for the failure of the contract.
Gets the type of contract that failed.
Indicates whether the Contract.ContractFailed event has been handled.
Gets the message that describes the Contract.ContractFailed event.
Gets the original exception that caused the Contract.ContractFailed event.
Indicates whether the code contract escalation policy should be applied.
Determines whether the specified object is equal to the current object.(Inherited from Object.)
Serves as the default hash function. (Inherited from Object.)
Sets the ContractFailedEventArgs.Handled property to true.
Sets the ContractFailedEventArgs.Unwind property to true.
Returns a string that represents the current object.(Inherited from Object.)
A Contract.ContractFailed event when a contract fails. The ContractFailed event enables a managed application environment such as an interactive interpreter, a Web browser host, a test harness, or a logging infrastructure to be notified of contract failures. The event requires full trust.object is passed to the
Available since 4.5
Available since 4.0
Portable Class Library
Supported in: portable .NET platforms
Windows Phone Silverlight
Available since 8.0
Available since 8.1
Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.