ConstraintException 构造函数
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
初始化 ConstraintException 类的新实例。
重载
ConstraintException() |
初始化 ConstraintException 类的新实例。 这是无参数构造函数。 |
ConstraintException(String) |
使用指定的字符串初始化 ConstraintException 类的新实例。 |
ConstraintException(SerializationInfo, StreamingContext) |
已过时.
使用指定的序列化和流上下文初始化 ConstraintException 类的新实例。 |
ConstraintException(String, Exception) |
使用指定的字符串和内部异常初始化 ConstraintException 类的新实例。 |
ConstraintException()
- Source:
- DataException.cs
- Source:
- DataException.cs
- Source:
- DataException.cs
初始化 ConstraintException 类的新实例。 这是无参数构造函数。
public:
ConstraintException();
public ConstraintException ();
Public Sub New ()
适用于
ConstraintException(String)
- Source:
- DataException.cs
- Source:
- DataException.cs
- Source:
- DataException.cs
使用指定的字符串初始化 ConstraintException 类的新实例。
public:
ConstraintException(System::String ^ s);
public ConstraintException (string? s);
public ConstraintException (string s);
new System.Data.ConstraintException : string -> System.Data.ConstraintException
Public Sub New (s As String)
参数
- s
- String
引发异常时显示的字符串。
适用于
ConstraintException(SerializationInfo, StreamingContext)
- Source:
- DataException.cs
- Source:
- DataException.cs
- Source:
- DataException.cs
注意
This API supports obsolete formatter-based serialization. It should not be called or extended by application code.
使用指定的序列化和流上下文初始化 ConstraintException 类的新实例。
protected:
ConstraintException(System::Runtime::Serialization::SerializationInfo ^ info, System::Runtime::Serialization::StreamingContext context);
protected ConstraintException (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 ConstraintException (System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context);
new System.Data.ConstraintException : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> System.Data.ConstraintException
[<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.Data.ConstraintException : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> System.Data.ConstraintException
Protected Sub New (info As SerializationInfo, context As StreamingContext)
参数
- info
- SerializationInfo
将对象序列化或反序列化所必需的数据。
- context
- StreamingContext
指定的序列化流的源和目标的说明。
- 属性
适用于
ConstraintException(String, Exception)
- Source:
- DataException.cs
- Source:
- DataException.cs
- Source:
- DataException.cs
使用指定的字符串和内部异常初始化 ConstraintException 类的新实例。
public:
ConstraintException(System::String ^ message, Exception ^ innerException);
public ConstraintException (string? message, Exception? innerException);
public ConstraintException (string message, Exception innerException);
new System.Data.ConstraintException : string * Exception -> System.Data.ConstraintException
Public Sub New (message As String, innerException As Exception)
参数
- message
- String
引发异常时显示的字符串。
- innerException
- Exception
获取导致当前异常的 Exception
实例。