title: Cannot deserialize type without setter
body: <p>I have binary serialized objects in database. They are serialized with protobuf.
  Now I need to generate some viewer to see the content of Database.
  So, i read stream from database and deserialized it back to the objects.
  It works and the result is list of objects:</p>
  
  <pre><code>var dbData = readData(someType);//it is IList collection
  </code></pre>
  
  <p>Now, I would like to save this list of objects to file to see the content of database. I thought it would be the best to save it to xml. So, i have tried:</p>
  
  <pre><code>var serializer = new XmlSerializer(dbData.GetType());
  </code></pre>
  
  <p>But i get an error:  Cannot deserialize type 'My.Entities.IdBase' because it contains property 'Key' which has no public setter.</p>
  
  <p>What now? I can't change the class definitions to have setters. 
  Should i save objects to json or plain text instead? Or should i extract all properties and values and save it to some xml? Any code example?</p>