DomainClassXmlSerializer.ReadRootElement(SerializationContext, ModelElement, XmlReader, ISchemaResolver) Método

Definição

Método público ReadRootElement () que desserializa um elemento de nível raiz de XML.Public ReadRootElement() method that deserializes a root-level element from XML. A diferença entre o elemento de nível raiz e os elementos REST no XML é que a raiz pode conter informações adicionais, como o esquema, a versão, etc. A implementação padrão simplesmente chama o método Read (), cabe às implementações derivadas fazer verificações adicionais.The difference between root-level element and the rest elements in the XML is that the root may carry additional information like schema, version, etc. The default implementation just calls Read() method, it's up to the derived implementations to do any additional checks.

public:
 virtual void ReadRootElement(Microsoft::VisualStudio::Modeling::SerializationContext ^ serializationContext, Microsoft::VisualStudio::Modeling::ModelElement ^ element, System::Xml::XmlReader ^ reader, Microsoft::VisualStudio::Modeling::ISchemaResolver ^ schemaResolver);
public virtual void ReadRootElement (Microsoft.VisualStudio.Modeling.SerializationContext serializationContext, Microsoft.VisualStudio.Modeling.ModelElement element, System.Xml.XmlReader reader, Microsoft.VisualStudio.Modeling.ISchemaResolver schemaResolver);
abstract member ReadRootElement : Microsoft.VisualStudio.Modeling.SerializationContext * Microsoft.VisualStudio.Modeling.ModelElement * System.Xml.XmlReader * Microsoft.VisualStudio.Modeling.ISchemaResolver -> unit
override this.ReadRootElement : Microsoft.VisualStudio.Modeling.SerializationContext * Microsoft.VisualStudio.Modeling.ModelElement * System.Xml.XmlReader * Microsoft.VisualStudio.Modeling.ISchemaResolver -> unit
Public Overridable Sub ReadRootElement (serializationContext As SerializationContext, element As ModelElement, reader As XmlReader, schemaResolver As ISchemaResolver)

Parâmetros

serializationContext
SerializationContext

Contexto de serialização.Serialization context.

element
ModelElement

Instância de ModelElement na memória que obterá os dados desserializados.In-memory ModelElement instance that will get the deserialized data.

reader
XmlReader

XmlReader para leitura de dados serializados.XmlReader to read serialized data from.

schemaResolver
ISchemaResolver

Um ISchemaResolver que permite que o serializador faça a validação de esquema no elemento raiz (e tudo dentro dele).An ISchemaResolver that allows the serializer to do schema validation on the root element (and everything inside it).

Aplica-se a