You may want to look at how you can use the built-in futures of .NET to serialize and deserilize an object into XML, rather than creating
I have used these techniques successfully on a couple of projects but don’t have the implementation details handy right now. I will try to update my answer with my own examples sometime later.
Here's a couple of examples that Google returned:
XML Serialization in .NET by Venkat Subramaniam http://www.agiledeveloper.com/articles/XMLSerialization.pdf
How to Serialize and DeSerialize an object into XML http://www.dotnetfunda.com/articles/article98.aspx
Customize your .NET object XML serialization with .NET XML attributes http://blogs.microsoft.co.il/blogs/rotemb/archive/2008/07/27/customize-your-net-object-xml-serialization-with-net-xml-attributes.aspx
ToXML()
method on every class that essentially just Data Transfer Object. I have used these techniques successfully on a couple of projects but don’t have the implementation details handy right now. I will try to update my answer with my own examples sometime later.
Here's a couple of examples that Google returned:
XML Serialization in .NET by Venkat Subramaniam http://www.agiledeveloper.com/articles/XMLSerialization.pdf
How to Serialize and DeSerialize an object into XML http://www.dotnetfunda.com/articles/article98.aspx
Customize your .NET object XML serialization with .NET XML attributes http://blogs.microsoft.co.il/blogs/rotemb/archive/2008/07/27/customize-your-net-object-xml-serialization-with-net-xml-attributes.aspx
Before we answer this Question, Lets see what are different view scopes present in a list.
View Scope
SPViewScope is a SharePoint enumeration, which has values Default, FilesOnly, Recursive, RecursiveAll.
->Folder 1
Item 1
Item 2
->Item 3
Consider a SHAREPOINT list which has items in the above hierarchy.i.e. 'Folder 1' and 'Item 3' directly at the top level and 'Item 1 ,Item 2' inside the 'Folder 1 '.
Now lets set different scopes and check out what items are seen in the view.
Note : The scope can be set to SPview.Scope or to an SPQuery.Scope
Default