Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

IXmlSerializable Interface

[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]

Provides custom formatting for XML serialization and deserialization to control how your object is serialized or deserialized by the XmlSerializer.

Namespace:  System.Xml.Serialization
Assembly:  System.Xml (in System.Xml.dll)

public interface IXmlSerializable

The IXmlSerializable type exposes the following members.

  NameDescription
Public methodGetSchemaThis method is reserved and should not be used. When implementing the IXmlSerializable interface, you should return a null reference (Nothing in Visual Basic) from this method.
Public methodReadXmlGenerates an object from its XML representation.
Public methodWriteXmlConverts an object into its XML representation.
Top

To control the serialization, implement the ReadXml and WriteXml methods to control the XmlReader and XmlWriter classes used to read and write the XML.

Windows Phone OS

Supported in: 8.1, 8.0, 7.1, 7.0

Windows Phone

Show: