1

Closed

Provide a property for the DataContractSurrogate in DataContractMessageSerializer

description

In the DataContractMessageSerializer when the serializer is instantiated there is a parameter to specify a surrogate. The surrogate can be used to provide a class that can override serialization. We use it to remove nHibernate lazy-loading data when our entities are serialized, and also to have our entity classes deserialize collections as List<> (instead of arrays). The patch is to add this in DataContractMessageSerializer.cs, attached to this ticket. We figured this is the most open way to provide this functionality (override serialization) and something that's more important with the DataContract serializer than perhaps XmlSerializer.

file attachments

Closed Jul 8, 2010 at 5:02 AM by HakanL

comments

HakanL wrote Jul 8, 2010 at 5:07 AM

Added to trunk

wrote Feb 14, 2013 at 2:23 AM

wrote May 16, 2013 at 6:46 AM