title: how to serialize List<T> when T is not serializable
body: <p><strong>Case:</strong></p>
  
  <p>Pass a unserializable parameter cross AppDomain.</p>
  
  <p>Following is some method which i want to call in remote domain;</p>
  
  <pre><code>public RemoteClass
  {
    public Test(Class1 obj);
    public Test(List&lt;Class1&gt; obj);
  }
  </code></pre>
  
  <p><strong>Define:</strong></p>
  
  <pre><code>Class1    :   un-serializable
  
  [Serializable]
  Class2 : Class1  , ISerializable  //mark Class2 serializable
  {
      //.....
  }
  </code></pre>
  
  <p><strong>Following code used to test:</strong></p>
  
  <pre><code>using (MemoryStream s = new MemoryStream())
  {
      BinaryFormatter f = new BinaryFormatter();
      f.Serialize(s, obj);
  }
  </code></pre>
  
  <p><strong>Test result:</strong></p>
  
  <pre><code>obj                                      result
  
  Class1 obj=new Class1();                 exception
  
  Class1 obj=new Class2();                 success
  
  List&lt;Class1&gt; obj=new List&lt;Class1);       exception  when obj contain some element;
  obj.Add(new Class1();   
  
  List&lt;Class1&gt; obj=new List&lt;Class1);       exception  when obj contain some element; //how???
  obj.Add(new Class2();
  
  List&lt;Class2&gt; obj=new List&lt;Class2);       success;
  obj.Add(new Class2();   
  </code></pre>
  
  <p>Class1 is not a serializable calss, and I cannot modify it, so I have define Class2 which inherits from Class1 and implements ISerializable.  I can pass an instance of <code>Class2</code> when a method needs a instance of <code>Class1</code> in test result and this solution is successful, however for <code>List&lt;Class1&gt;</code> this does not work.</p>