DomainPropertySerializer.TryCreateInstance Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
This method creates a correct instance of DomainProperty based on the tag currently pointed by the reader. If the reader is positioned at a serialized DomainProperty, a new DomainProperty instance will be created in the given partition, otherwise null is returned.
public:
override Microsoft::VisualStudio::Modeling::ModelElement ^ TryCreateInstance(Microsoft::VisualStudio::Modeling::SerializationContext ^ serializationContext, System::Xml::XmlReader ^ reader, Microsoft::VisualStudio::Modeling::Partition ^ partition);
public override Microsoft.VisualStudio.Modeling.ModelElement TryCreateInstance (Microsoft.VisualStudio.Modeling.SerializationContext serializationContext, System.Xml.XmlReader reader, Microsoft.VisualStudio.Modeling.Partition partition);
override this.TryCreateInstance : Microsoft.VisualStudio.Modeling.SerializationContext * System.Xml.XmlReader * Microsoft.VisualStudio.Modeling.Partition -> Microsoft.VisualStudio.Modeling.ModelElement
Public Overrides Function TryCreateInstance (serializationContext As SerializationContext, reader As XmlReader, partition As Partition) As ModelElement
Parameters
- serializationContext
- SerializationContext
Serialization context.
- reader
- XmlReader
XmlReader to read serialized data from.
- partition
- Partition
Partition in which new elements should be created.
Returns
Created DomainProperty instance, or null if the reader is not pointing to a serialized DomainProperty instance.
Remarks
The caller will guarantee that the reader is positioned at open XML tag of the next element being read. This method should not move the reader; the reader should remain at the same position when this method returns.