InvalidChannelBindingException Konstruktorer

Definition

Initierar en ny instans av InvalidChannelBindingException klassen.

Överlagringar

Name Description
InvalidChannelBindingException()

Initierar en ny instans av InvalidChannelBindingException klassen.

InvalidChannelBindingException(String)

Initierar en ny instans av InvalidChannelBindingException klassen med ett angivet felmeddelande.

InvalidChannelBindingException(SerializationInfo, StreamingContext)

Initierar en ny instans av InvalidChannelBindingException klassen med serialiseringsinformation och strömningskontext angiven.

InvalidChannelBindingException(String, Exception)

Initierar en ny instans av InvalidChannelBindingException klassen med ett angivet felmeddelande och en referens till det inre undantaget som är orsaken till undantaget.

InvalidChannelBindingException()

Initierar en ny instans av InvalidChannelBindingException klassen.

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

Gäller för

InvalidChannelBindingException(String)

Initierar en ny instans av InvalidChannelBindingException klassen med ett angivet felmeddelande.

public:
 InvalidChannelBindingException(System::String ^ message);
public InvalidChannelBindingException(string message);
new System.ServiceModel.Channels.InvalidChannelBindingException : string -> System.ServiceModel.Channels.InvalidChannelBindingException
Public Sub New (message As String)

Parametrar

message
String

Felmeddelandet som förklarar orsaken till undantaget.

Kommentarer

Använd den här konstruktorn när du vill skicka ett felmeddelande till användaren. Innehållet i meddelandeparametern bör vara begripligt för användaren. Anroparen för den här konstruktorn krävs för att säkerställa att den här strängen har lokaliserats för den aktuella systemkulturen.

Om du också vill skicka en referens till det inre undantaget som är orsaken till undantaget samt ett angivet felmeddelande till användaren använder du InvalidChannelBindingException(String, Exception) konstruktorn.

Gäller för

InvalidChannelBindingException(SerializationInfo, StreamingContext)

Initierar en ny instans av InvalidChannelBindingException klassen med serialiseringsinformation och strömningskontext angiven.

protected:
 InvalidChannelBindingException(System::Runtime::Serialization::SerializationInfo ^ info, System::Runtime::Serialization::StreamingContext context);
protected InvalidChannelBindingException(System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context);
new System.ServiceModel.Channels.InvalidChannelBindingException : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> System.ServiceModel.Channels.InvalidChannelBindingException
Protected Sub New (info As SerializationInfo, context As StreamingContext)

Parametrar

info
SerializationInfo

Som SerializationInfo innehåller alla data som krävs för att serialisera undantaget.

context
StreamingContext

Det StreamingContext som anger källan och målet för strömmen.

Kommentarer

Den här konstruktorn anropas under deserialiseringen för att rekonstruera undantagsobjektet som överförs via en ström.

Gäller för

InvalidChannelBindingException(String, Exception)

Initierar en ny instans av InvalidChannelBindingException klassen med ett angivet felmeddelande och en referens till det inre undantaget som är orsaken till undantaget.

public:
 InvalidChannelBindingException(System::String ^ message, Exception ^ innerException);
public InvalidChannelBindingException(string message, Exception innerException);
new System.ServiceModel.Channels.InvalidChannelBindingException : string * Exception -> System.ServiceModel.Channels.InvalidChannelBindingException
Public Sub New (message As String, innerException As Exception)

Parametrar

message
String

Felmeddelandet som förklarar orsaken till undantaget.

innerException
Exception

Det Exception som gjorde att det aktuella undantaget utlöstes.

Kommentarer

Använd den här konstruktorn när du vill skicka ett felmeddelande och information om ett inre undantag till användaren.

Ett undantag som genereras som ett direkt resultat av ett tidigare undantag kan innehålla en referens till det tidigare undantaget i InnerException egenskapen. Egenskapen InnerException returnerar samma värde som skickas till konstruktorn eller en null referens (Nothing i Visual Basic) om egenskapen InnerException inte tillhandahåller konstruktorn det inre undantagsvärdet.

Gäller för