XmlSchemaImporter 類別

定義

針對 XML 結構描述項目宣告產生 .NET Framework 型別的內部對應,包括 WSDL 文件中的常值 (Literal) XSD 訊息部分。Generates internal mappings to .NET Framework types for XML schema element declarations, including literal XSD message parts in a WSDL document.

此 API 支援此產品基礎結構,但無法直接用於程式碼之中。

public ref class XmlSchemaImporter : System::Xml::Serialization::SchemaImporter
public class XmlSchemaImporter : System.Xml.Serialization.SchemaImporter
type XmlSchemaImporter = class
    inherit SchemaImporter
Public Class XmlSchemaImporter
Inherits SchemaImporter
繼承
XmlSchemaImporter
繼承
XmlSchemaImporter

備註

從 Web 服務描述語言(WSDL)檔產生用戶端 proxy 類別或抽象伺服器類別時, Web 服務描述語言工具(wsdl.exe)ServiceDescriptionImporter 類別會使用 XmlSchemaImporter 類別。The XmlSchemaImporter class is used by the Web Services Description Language Tool (Wsdl.exe) and the ServiceDescriptionImporter class while generating client proxy classes or abstract server classes from a Web Services Description Language (WSDL) document. 從 XML 架構定義(XSD)檔產生類別時, Web 服務描述語言工具(wsdl.exe)也會使用類別。The class is also used by the Web Services Description Language Tool (Wsdl.exe) while generating classes from XML Schema Definition (XSD) documents. 請改用 Wsdl.exe 或 Xsd.exe,而不是直接使用這個類別。Instead of using this class directly, use Wsdl.exe or Xsd.exe.

XmlSchemaImporter 類別具有方法,可為 XSD 檔中所定義的專案或 WSDL 檔案中的元件,產生 .NET Framework 類型的內部對應。The XmlSchemaImporter class has methods to generate internal mappings to .NET Framework types for elements defined in an XSD document or as parts in a WSDL document. 下列清單顯示 Wsdl.exe 使用類別的時機:The following list shows when the class is used by Wsdl.exe:

  • WSDL 檔案會指定常值用法,其中 SOAP 訊息參數和傳回值(或要求和回應檔)的內容實際上是以 XML 架構定義來指定。A WSDL document specifies literal use, where the content of SOAP message parameters and return values (or request and response documents) is literally specified with XML schema definitions.

  • WSDL 檔案會透過 HTTP GET 和 HTTP POST 作業,指定 Web 服務的 .NET Framework 非 SOAP 的執行。A WSDL document specifies the .NET Framework's non-SOAP implementations of Web services via the HTTP-GET and HTTP-POST operations.

建構函式

XmlSchemaImporter(XmlSchemas)

初始化 XmlSchemaImporter 類別的新執行個體,並採用 XmlSchema 物件的集合,表示 WSDL 文件中定義之 SOAP 常值訊息所使用的 XML 結構描述。Initializes a new instance of the XmlSchemaImporter class, taking a collection of XmlSchema objects representing the XML schemas used by SOAP literal messages defined in a WSDL document.

XmlSchemaImporter(XmlSchemas, CodeGenerationOptions, CodeDomProvider, ImportContext)

初始化 XmlSchemaImporter 類別的新執行個體。Initializes a new instance of the XmlSchemaImporter class.

XmlSchemaImporter(XmlSchemas, CodeGenerationOptions, ImportContext)

使用指定的程式碼產生選項和匯入內容,針對 XML 結構描述的集合初始化 XmlSchemaImporter 類別的新執行個體。Initializes a new instance of the XmlSchemaImporter class for a collection of XML schemas, using the specified code generation options and import context.

XmlSchemaImporter(XmlSchemas, CodeIdentifiers)

初始化 XmlSchemaImporter 類別的新執行個體,並採用 XmlSchema 物件的集合,表示由 SOAP 常值訊息所使用的 XML 結構描述,再加上針對 Web 服務描述語言 (WSDL) 文件中定義的繫結所產生的類別。Initializes a new instance of the XmlSchemaImporter class, taking a collection of XmlSchema objects that represents the XML schemas used by SOAP literal messages, plus classes being generated for bindings defined in a Web Services Description Language (WSDL) document.

XmlSchemaImporter(XmlSchemas, CodeIdentifiers, CodeGenerationOptions)

初始化 XmlSchemaImporter 類別的新執行個體,並採用 XmlSchema 物件的集合,表示由 SOAP 常值訊息所使用的 XML 結構描述,再加上針對 WSDL 文件中定義的繫結所產生的類別,以及 CodeGenerationOptions 列舉值。Initializes a new instance of the XmlSchemaImporter class, taking a collection of XmlSchema objects that represents the XML schemas used by SOAP literal messages, plus classes being generated for bindings defined in a WSDL document, and a CodeGenerationOptions enumeration value.

屬性

Extensions

取得結構描述匯入工具擴充的集合。Gets a collection of schema importer extensions.

(繼承來源 SchemaImporter)

方法

Equals(Object)

判斷指定的物件是否等於目前的物件。Determines whether the specified object is equal to the current object.

(繼承來源 Object)
GetHashCode()

作為預設雜湊函數。Serves as the default hash function.

(繼承來源 Object)
GetType()

取得目前執行個體的 TypeGets the Type of the current instance.

(繼承來源 Object)
ImportAnyType(XmlQualifiedName, String)

針對 WSDL 文件中定義的單一 (SOAP) 常值項目部分,產生內部型別對應資訊。Generates internal type mapping information for a single, (SOAP) literal element part defined in a WSDL document.

ImportDerivedTypeMapping(XmlQualifiedName, Type)

產生 XML 結構描述文件中所定義之項目的內部型別對應資訊。Generates internal type mapping information for an element defined in an XML schema document.

ImportDerivedTypeMapping(XmlQualifiedName, Type, Boolean)

針對 XML 結構描述文件中定義的項目產生內部型別對應資訊,或當做 WSDL 文件中的部分。Generates internal type mapping information for an element defined in an XML schema document or as a part in a WSDL document.

ImportMembersMapping(String, String, SoapSchemaMember[])

針對在 WSDL 文件中定義之常值使用 SOAP 訊息的項目部分產生內部型別對應資訊。Generates internal type mapping information for the element parts of a literal-use SOAP message defined in a WSDL document.

ImportMembersMapping(XmlQualifiedName)

針對在 WSDL 文件中定義之常值用法 SOAP 訊息的單一項目部分產生內部型別對應資訊。Generates internal type mapping information for a single element part of a literal-use SOAP message defined in a WSDL document.

ImportMembersMapping(XmlQualifiedName[])

針對在 WSDL 文件中定義之常值使用 SOAP 訊息的項目部分產生內部型別對應資訊。Generates internal type mapping information for the element parts of a literal-use SOAP message defined in a WSDL document.

ImportMembersMapping(XmlQualifiedName[], Type, Boolean)

針對在 WSDL 文件中定義之常值使用 SOAP 訊息的項目部分產生內部型別對應資訊。Generates internal type mapping information for the element parts of a literal-use SOAP message defined in a WSDL document.

ImportSchemaType(XmlQualifiedName)

產生 XML 結構描述文件中所定義之項目的內部型別對應資訊。Generates internal type mapping information for an element defined in an XML schema document.

ImportSchemaType(XmlQualifiedName, Type)

產生 XML 結構描述文件中所定義之項目的內部型別對應資訊。Generates internal type mapping information for an element defined in an XML schema document.

ImportSchemaType(XmlQualifiedName, Type, Boolean)

產生 XML 結構描述文件中所定義之項目的內部型別對應資訊。Generates internal type mapping information for an element defined in an XML schema document.

ImportTypeMapping(XmlQualifiedName)

產生 XML 結構描述文件中所定義之項目的內部型別對應資訊。Generates internal type mapping information for an element defined in an XML schema document.

MemberwiseClone()

建立目前 Object 的淺層複本 (Shallow Copy)。Creates a shallow copy of the current Object.

(繼承來源 Object)
ToString()

傳回代表目前物件的字串。Returns a string that represents the current object.

(繼承來源 Object)

適用於

另請參閱