R – .NET XML Serialization Helper Class

netxml-serialization

I Collected the info from one of the previous StackOverflow Q & A that

The following items can be serialized using the XmlSerializer class:

  • Public read/write properties and fields of public classes
  • Classes that implement ICollection or IEnumerable
  • XmlElement objects
  • XmlNode objects
  • DataSet objects

My Question is how can we develop a XmlSerialize Helper class that takes a Generic Collection as parameter for Xml Serialization.

Best Answer

http://www.codeproject.com/KB/XML/CustomXmlSerializer.aspx?msg=3101055

SUMMARY:CustomXmlSerializer is an alternative to XmlSerializer, supporting both shallow and deep serialization of ArrayLists, Collections, and Dictionaries.