The following model class serializes
to
[XmlRoot]
public class A
{
[XmlAttribute]
public string Period { get; set; }
public List<C> B { get; set; }
}
<?xml version=1.0>
<A Period="Today">
<B>
<C>
</C>
<C>
</C>
</B>
</A>
Now, I dont want that <B>
(List of objects should directly be listed under XmlRoot
)
The resulting XML should look like,
<A Period="Today">
<C>
</C>
<C>
</C>
</A>
Any ideas how ?