XmlSerializationReader.CreateAbstractTypeException(String, String) 方法

定义

创建一个 InvalidOperationException,该异常指示要反序列化的对象应是抽象对象。Creates an InvalidOperationException that indicates that an object being deserialized should be abstract.

此 API 支持产品基础结构,不能在代码中直接使用。

protected:
 Exception ^ CreateAbstractTypeException(System::String ^ name, System::String ^ ns);
protected Exception CreateAbstractTypeException (string name, string? ns);
protected Exception CreateAbstractTypeException (string name, string ns);
member this.CreateAbstractTypeException : string * string -> Exception
Protected Function CreateAbstractTypeException (name As String, ns As String) As Exception

参数

name
String

抽象类型的名称。The name of the abstract type.

ns
String

抽象类型的 .NET Framework 命名空间。The .NET Framework namespace of the abstract type.

返回

Exception

一个 InvalidOperationException 异常。An InvalidOperationException exception.

注解

的受保护成员 XmlSerializationReader 仅供在 .NET FRAMEWORK XML 序列化基础结构内部使用的派生类使用。The protected members of XmlSerializationReader are intended only for use by derived classes that are used internally within the .NET Framework XML serialization infrastructure.

适用于