Compartilhar via


MoveableDecoratorHostShapeSerializer.Write Method

Definition

Unlike DecoratorHostShape, MoveableDecoratorHostShape does need to be serialized to preserve the location information. However, due to the special handling of decorators and host shapes in CDS, the normal generated serialization won't work. So we short-circuit the generated serializer here, and handle the serialization in ShapeElementSerializer.CustomWriteElements() instead.

public:
 override void Write(Microsoft::VisualStudio::Modeling::SerializationContext ^ serializationContext, Microsoft::VisualStudio::Modeling::ModelElement ^ element, System::Xml::XmlWriter ^ writer, Microsoft::VisualStudio::Modeling::RootElementSettings ^ rootElementSettings);
public override void Write (Microsoft.VisualStudio.Modeling.SerializationContext serializationContext, Microsoft.VisualStudio.Modeling.ModelElement element, System.Xml.XmlWriter writer, Microsoft.VisualStudio.Modeling.RootElementSettings rootElementSettings);
override this.Write : Microsoft.VisualStudio.Modeling.SerializationContext * Microsoft.VisualStudio.Modeling.ModelElement * System.Xml.XmlWriter * Microsoft.VisualStudio.Modeling.RootElementSettings -> unit
Public Overrides Sub Write (serializationContext As SerializationContext, element As ModelElement, writer As XmlWriter, rootElementSettings As RootElementSettings)

Parameters

serializationContext
SerializationContext
element
ModelElement
writer
XmlWriter
rootElementSettings
RootElementSettings

Applies to