I would like to serialize and deserialize objects without having to worry about the entire class graph.
Flexibility is key. I would like to be able to serialize any object passed to me without complete attributes needed throughout the entire object graph.
That means that Binary Serialization is not an option as it only works with the other .NET Platforms. I would also like something readable by a person, and thus decipherable by a management program and other interpreters.
I've found problems using the DataContract, JSON, and XML Serializers.
- Most of these errors seem to center around Serialization of Lists/Dictionaries (i.e. XML Serializable Generic Dictionary).
- "Add any types not known statically to the list of known types - for example, by using the KnownTypeAttribute attribute or by adding them to the list of known types passed to DataContractSerializer."
Please base your answers on actual experiences and not theory or reading of an article.