XmlSchemas.Compile(ValidationEventHandler, Boolean) Метод

Определение

Обрабатывает имена элементов и атрибутов в xml-схемах и, при необходимости, проверяет xml-схемы.

Этот API поддерживает инфраструктуру продукта и не предназначен для использования непосредственно из программного кода.

public:
 void Compile(System::Xml::Schema::ValidationEventHandler ^ handler, bool fullCompile);
[System.Diagnostics.CodeAnalysis.RequiresDynamicCode("XML serializer relies on dynamic code generation which is not available with Ahead of Time compilation")]
[System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("Members from serialized types may be trimmed if not referenced directly")]
public void Compile(System.Xml.Schema.ValidationEventHandler? handler, bool fullCompile);
public void Compile(System.Xml.Schema.ValidationEventHandler? handler, bool fullCompile);
[System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("Members from serialized types may be trimmed if not referenced directly")]
public void Compile(System.Xml.Schema.ValidationEventHandler? handler, bool fullCompile);
public void Compile(System.Xml.Schema.ValidationEventHandler handler, bool fullCompile);
[<System.Diagnostics.CodeAnalysis.RequiresDynamicCode("XML serializer relies on dynamic code generation which is not available with Ahead of Time compilation")>]
[<System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("Members from serialized types may be trimmed if not referenced directly")>]
member this.Compile : System.Xml.Schema.ValidationEventHandler * bool -> unit
member this.Compile : System.Xml.Schema.ValidationEventHandler * bool -> unit
[<System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("Members from serialized types may be trimmed if not referenced directly")>]
member this.Compile : System.Xml.Schema.ValidationEventHandler * bool -> unit
Public Sub Compile (handler As ValidationEventHandler, fullCompile As Boolean)

Параметры

handler
ValidationEventHandler

Значение, ValidationEventHandler указывающее метод обратного вызова, который обрабатывает ошибки и предупреждения во время проверки схемы XML, если задан trueстрогий параметр.

fullCompile
Boolean

true Значение Compile(ValidationEventHandler, Boolean) , чтобы проверить xml-схемы в коллекции с помощью метода XmlSchemas класса; в противном случае false.

Атрибуты

Комментарии

В следующем списке определяются ситуации, Compile в которых вызывается метод:

  • По классу ServiceDescriptionReflector при создании ServiceDescription объектов из классов, которые определяются как веб-службы.

  • С помощью средства Wsdl.exe или ServiceDescriptionImporter класса при создании клиентских прокси-классов или абстрактных классов серверов из документа языка описания веб-служб (WSDL).

  • С помощью средства Xsd.exe при создании XML-схем из типов, найденных в сборках.

Вместо прямого вызова Compile метода используйте ранее упомянутые классы или инструменты.

Применяется к