DynamoDS/Dynamo — pull request #1683 by frankfralick (2014-05-21 21:19:53+00:00)
Title: Changed SoapFormatter to BinaryFormatter.

Persistence between Dynamo sessions is not working for me for implementations of ISerializable that have an Id type that uses generics. For example, in your class MultipleSerializableId, you are storing List and List in your named data slot. This works for binding in-session. I could be wrong because I have not tested this with Revit, but I don't believe any method that sets trace data with SetElementsForTrace will be able to save trace data to the .dyn file as you currently have it because SoapFormatter doesn't support doing that. Have you tested between-session rebinding with Revit for MultipleSerializableId? I will be really confused if you have and it works. I have tested this change in Inventor and it works.

If there is a reason that it has to be SoapFormatter, can we talk about a way to switch between the two? Or SoapFormatter be tried first, then BinaryFormatter if that fails? For trace data that has to store lots of disparate data, having to resort to replacing something like List> to a series of arrays, zipping them back together, etc doesn't seem good.