"Deep" XML Serialization of objects

  • Thread starter Thread starter Jesper Denmark
  • Start date Start date
J

Jesper Denmark

Hi,

Is deep serialization possible using XML. Know any good
tutorials?.

By deep serialization I mean the ability that an object
being serialized automatically serialize its members. E.g

Class A
{
public string x;
}

Class B
{
public string y;
public A a;
}

When serializing B an xml output like:

<classBroot>
<y>y-string</y>
<classAroot>
<x>x-string</x>
</classAroot>
<classBroot>
 
Jesper,

Serialization automatically implies "deep" behavior. If an object is
serialized, then all of the information that the object references will be
serialized as well. Only members that are marked as non serializable will
not be serialized.

Hope this helps.
 
Back
Top