title: How to rename <ArrayOf> XML attribute that generated after serializing List of objects
body: <p>I am serializing List of objects  <code>List&lt;TestObject&gt;</code>
  , and XmlSerializer generates <code>&lt;ArrayOfTestObject&gt;</code> attribute, I want rename it or remove it.<br>
  Can it be done with creating new class that encapsulated List as field?  </p>
  
  <pre><code> [XmlRoot("Container")]    
   public class TestObject
   {
       public TestObject() { }                         
       public string Str { get; set; }                         
   }
  
   List&lt;TestObject&gt; tmpList = new List&lt;TestObject&gt;();
  
   TestObject TestObj = new TestObject();
   TestObj.Str = "Test";
  
   TestObject TestObj2 = new TestObject();
   TestObj2.Str = "xcvxc";
  
   tmpList.Add(TestObj);
   tmpList.Add(TestObj2);
  
  
   XmlWriterSettings settings = new XmlWriterSettings();
   settings.OmitXmlDeclaration = true;
   settings.Indent = true;
   XmlSerializer serializer = new XmlSerializer(typeof(List&lt;TestObject&gt;));
  
   using (XmlWriter writer = XmlWriter.Create(@"C:\test.xml", settings))
   {              
       XmlSerializerNamespaces namespaces = new XmlSerializerNamespaces();
       namespaces.Add(string.Empty, string.Empty);
       serializer.Serialize(writer, tmpList, namespaces);                            
  }
  
  
  &lt;ArrayOfTestObject&gt;
    &lt;TestObject&gt;
      &lt;Str&gt;Test&lt;/Str&gt;
    &lt;/TestObject&gt;
    &lt;TestObject&gt;
      &lt;Str&gt;xcvxc&lt;/Str&gt;
    &lt;/TestObject&gt;
  &lt;/ArrayOfTestObject&gt;
  </code></pre>