SoapReflectionImporter.ImportTypeMapping 方法
定义
使用指定类型返回一个对象,该对象用于从一个类型映射到 XML 表示形式。Returns an object that is used to map from a type to an XML representation using the specified type.
重载
| ImportTypeMapping(Type) |
为 .NET 类型生成到 XML 架构元素的映射。Generates a mapping to an XML Schema element for a .NET type. |
| ImportTypeMapping(Type, String) |
为 .NET 类型生成到 XML 架构元素的映射。Generates a mapping to an XML Schema element for a .NET type. |
ImportTypeMapping(Type)
为 .NET 类型生成到 XML 架构元素的映射。Generates a mapping to an XML Schema element for a .NET type.
public:
System::Xml::Serialization::XmlTypeMapping ^ ImportTypeMapping(Type ^ type);
public System.Xml.Serialization.XmlTypeMapping ImportTypeMapping (Type type);
member this.ImportTypeMapping : Type -> System.Xml.Serialization.XmlTypeMapping
Public Function ImportTypeMapping (type As Type) As XmlTypeMapping
参数
- type
- Type
将为其生成类型映射的 .NET 类型。The .NET type for which to generate a type mapping.
返回
从一个类型到一个 XML 架构元素的 .NET 内部映射。Internal .NET mapping of a type to an XML Schema element.
注解
XML 架构元素使用 SOAP 编码进行序列化。The XML Schema element is serialized using SOAP encoding.
不需要 ImportTypeMapping 直接调用方法。You do not need to call the ImportTypeMapping method directly.
适用于
ImportTypeMapping(Type, String)
为 .NET 类型生成到 XML 架构元素的映射。Generates a mapping to an XML Schema element for a .NET type.
public:
System::Xml::Serialization::XmlTypeMapping ^ ImportTypeMapping(Type ^ type, System::String ^ defaultNamespace);
public System.Xml.Serialization.XmlTypeMapping ImportTypeMapping (Type type, string? defaultNamespace);
public System.Xml.Serialization.XmlTypeMapping ImportTypeMapping (Type type, string defaultNamespace);
member this.ImportTypeMapping : Type * string -> System.Xml.Serialization.XmlTypeMapping
Public Function ImportTypeMapping (type As Type, defaultNamespace As String) As XmlTypeMapping
参数
- type
- Type
将为其生成类型映射的 .NET 类型。The .NET type for which to generate a type mapping.
- defaultNamespace
- String
要使用的默认 XML 命名空间。The default XML namespace to use.
返回
从一个类型到一个 XML 架构元素的 .NET 内部映射。Internal .NET mapping of a type to an XML Schema element.
注解
XML 架构元素使用 SOAP 编码进行序列化。The XML Schema element is serialized using SOAP encoding.
不需要 ImportTypeMapping 直接调用方法。You do not need to call the ImportTypeMapping method directly.