November 2003
Intermediate to advanced
476 pages
14h 38m
English
XmlAttributeOverrides — System.Xml.Serialization (system.xml.dll) class
public class XmlAttributeOverrides { // Public Constructors public XmlAttributeOverrides( ); // Public Instance Properties public XmlAttributes this[ Type type, string member ]{get; } public XmlAttributes this[ Type type ]{get; } // Public Instance Methods public void Add( Type type, string member, XmlAttributes attributes); public void Add( Type type, XmlAttributes attributes); }
This type
contains a collection of XmlAttributes objects,
which are used to customize the way the
XmlSerializer serializes an object to XML. Its
Add( ) method has two overrides, one that takes a
System.Type indicating the type of object it
applies to and the XmlAttribute instance
containing the attributes, and one that takes those two parameters
plus a System.String containing the name of the
member of the type to which the attributes apply.
The XmlAttributeOverrides instance is passed to
the XmlSerializer constructor to create the
serializer with the overriden attributes.