SafeArrayTypeMismatchException Konstruktory
Definicja
Ważne
Niektóre informacje odnoszą się do produktu w wersji wstępnej, który może zostać znacząco zmodyfikowany przed wydaniem. Firma Microsoft nie udziela żadnych gwarancji, jawnych lub domniemanych, w odniesieniu do informacji podanych w tym miejscu.
Inicjuje nowe wystąpienie klasy SafeArrayTypeMismatchException.
Przeciążenia
| Nazwa | Opis |
|---|---|
| SafeArrayTypeMismatchException() |
Inicjuje |
| SafeArrayTypeMismatchException(String) |
Inicjuje nowe wystąpienie |
| SafeArrayTypeMismatchException(SerializationInfo, StreamingContext) |
Przestarzałe.
Inicjuje |
| SafeArrayTypeMismatchException(String, Exception) |
Inicjuje nowe wystąpienie SafeArrayTypeMismatchException klasy z określonym komunikatem o błędzie i odwołaniem do wyjątku wewnętrznego, który jest przyczyną tego wyjątku. |
SafeArrayTypeMismatchException()
Inicjuje SafeArrayTypeMismatchException nowe wystąpienie klasy z wartościami domyślnymi.
public:
SafeArrayTypeMismatchException();
public SafeArrayTypeMismatchException();
Public Sub New ()
Uwagi
SafeArrayTypeMismatchException dziedziczy z SystemException. Ten konstruktor ustawia właściwości Exception obiektu, jak pokazano w poniższej tabeli.
| Majątek | Wartość |
|---|---|
| InnerException |
null. |
| Message | Zlokalizowany ciąg komunikatu o błędzie. |
Dotyczy
SafeArrayTypeMismatchException(String)
Inicjuje nowe wystąpienie SafeArrayTypeMismatchException klasy z określonym komunikatem.
public:
SafeArrayTypeMismatchException(System::String ^ message);
public SafeArrayTypeMismatchException(string message);
public SafeArrayTypeMismatchException(string? message);
new System.Runtime.InteropServices.SafeArrayTypeMismatchException : string -> System.Runtime.InteropServices.SafeArrayTypeMismatchException
Public Sub New (message As String)
Parametry
- message
- String
Komunikat wskazujący przyczynę wyjątku.
Uwagi
SafeArrayTypeMismatchException dziedziczy z SystemException. Ten konstruktor ustawia właściwości Exception obiektu, jak pokazano w poniższej tabeli.
| Majątek | Wartość |
|---|---|
| InnerException |
null. |
| Message | message |
Dotyczy
SafeArrayTypeMismatchException(SerializationInfo, StreamingContext)
Uwaga
This API supports obsolete formatter-based serialization. It should not be called or extended by application code.
Inicjuje SafeArrayTypeMismatchException nowe wystąpienie klasy z danych serializacji.
protected:
SafeArrayTypeMismatchException(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 SafeArrayTypeMismatchException(System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context);
protected SafeArrayTypeMismatchException(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}")>]
new System.Runtime.InteropServices.SafeArrayTypeMismatchException : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> System.Runtime.InteropServices.SafeArrayTypeMismatchException
new System.Runtime.InteropServices.SafeArrayTypeMismatchException : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> System.Runtime.InteropServices.SafeArrayTypeMismatchException
Protected Sub New (info As SerializationInfo, context As StreamingContext)
Parametry
- info
- SerializationInfo
Obiekt, który przechowuje serializowane dane obiektu.
- context
- StreamingContext
Kontekstowe informacje o źródle lub miejscu docelowym.
- Atrybuty
Wyjątki
Parametr info ma wartość null.
Uwagi
Ten konstruktor jest wywoływany podczas deserializacji w celu ponownego utworzenia obiektu wyjątku przesyłanego przez strumień. Aby uzyskać więcej informacji, zobacz System.Runtime.Serialization.
SafeArrayTypeMismatchException dziedziczy z SystemException.
Dotyczy
SafeArrayTypeMismatchException(String, Exception)
Inicjuje nowe wystąpienie SafeArrayTypeMismatchException klasy z określonym komunikatem o błędzie i odwołaniem do wyjątku wewnętrznego, który jest przyczyną tego wyjątku.
public:
SafeArrayTypeMismatchException(System::String ^ message, Exception ^ inner);
public SafeArrayTypeMismatchException(string message, Exception inner);
public SafeArrayTypeMismatchException(string? message, Exception? inner);
new System.Runtime.InteropServices.SafeArrayTypeMismatchException : string * Exception -> System.Runtime.InteropServices.SafeArrayTypeMismatchException
Public Sub New (message As String, inner As Exception)
Parametry
- message
- String
Komunikat o błędzie wyjaśniający przyczynę wyjątku.
- inner
- Exception
Wyjątek, który jest przyczyną bieżącego wyjątku. Jeśli parametr inner nie jest null, bieżący wyjątek jest zgłaszany w bloku catch, który obsługuje wyjątek wewnętrzny.
Uwagi
Wyjątek zgłaszany bezpośrednio w wyniku poprzedniego wyjątku powinien zawierać odwołanie do poprzedniego wyjątku we właściwości InnerException. Właściwość InnerException zwraca tę samą wartość, która jest przekazywana do konstruktora, lub null, jeśli właściwość InnerException nie dostarcza wartości wyjątku wewnętrznego do konstruktora.
W poniższej tabeli przedstawiono początkowe wartości właściwości dla wystąpienia SafeArrayTypeMismatchException.
| Majątek | Wartość |
|---|---|
| InnerException | Odwołanie do wyjątku wewnętrznego. |
| Message | Ciąg komunikatu o błędzie. |