Επεξεργασία

Κοινή χρήση μέσω


InvalidDataContractException Constructors

Definition

Initializes a new instance of the InvalidDataContractException class.

Overloads

InvalidDataContractException()

Initializes a new instance of the InvalidDataContractException class.

InvalidDataContractException(String)

Initializes a new instance of the InvalidDataContractException class with the specified error message.

InvalidDataContractException(SerializationInfo, StreamingContext)
Obsolete.

Initializes a new instance of the InvalidDataContractException class with the specified SerializationInfo and StreamingContext.

InvalidDataContractException(String, Exception)

Initializes a new instance of the InvalidDataContractException class with the specified error message and inner exception.

InvalidDataContractException()

Source:
InvalidDataContractException.cs
Source:
InvalidDataContractException.cs
Source:
InvalidDataContractException.cs

Initializes a new instance of the InvalidDataContractException class.

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

Applies to

InvalidDataContractException(String)

Source:
InvalidDataContractException.cs
Source:
InvalidDataContractException.cs
Source:
InvalidDataContractException.cs

Initializes a new instance of the InvalidDataContractException class with the specified error message.

public:
 InvalidDataContractException(System::String ^ message);
public InvalidDataContractException (string message);
public InvalidDataContractException (string? message);
new System.Runtime.Serialization.InvalidDataContractException : string -> System.Runtime.Serialization.InvalidDataContractException
Public Sub New (message As String)

Parameters

message
String

A description of the error.

Applies to

InvalidDataContractException(SerializationInfo, StreamingContext)

Source:
InvalidDataContractException.cs
Source:
InvalidDataContractException.cs
Source:
InvalidDataContractException.cs

Caution

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

Initializes a new instance of the InvalidDataContractException class with the specified SerializationInfo and StreamingContext.

protected:
 InvalidDataContractException(System::Runtime::Serialization::SerializationInfo ^ info, System::Runtime::Serialization::StreamingContext context);
protected InvalidDataContractException (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 InvalidDataContractException (System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context);
new System.Runtime.Serialization.InvalidDataContractException : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> System.Runtime.Serialization.InvalidDataContractException
[<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.Runtime.Serialization.InvalidDataContractException : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> System.Runtime.Serialization.InvalidDataContractException
Protected Sub New (info As SerializationInfo, context As StreamingContext)

Parameters

info
SerializationInfo

A SerializationInfo that contains data needed to serialize and deserialize an object.

context
StreamingContext

A StreamingContext that specifies user context during serialization and deserialization.

Attributes

Remarks

This constructor is used in deserialization by one of the formatters in the System.Runtime.Serialization namespace.

Applies to

InvalidDataContractException(String, Exception)

Source:
InvalidDataContractException.cs
Source:
InvalidDataContractException.cs
Source:
InvalidDataContractException.cs

Initializes a new instance of the InvalidDataContractException class with the specified error message and inner exception.

public:
 InvalidDataContractException(System::String ^ message, Exception ^ innerException);
public InvalidDataContractException (string message, Exception innerException);
public InvalidDataContractException (string? message, Exception? innerException);
new System.Runtime.Serialization.InvalidDataContractException : string * Exception -> System.Runtime.Serialization.InvalidDataContractException
Public Sub New (message As String, innerException As Exception)

Parameters

message
String

A description of the error.

innerException
Exception

The original Exception.

Applies to