Bidirectional Serialization with Linq
- by Andy
Anyone know why only undirectional serialization is supported in the Linq designer?
Consider the following example:
Say we have a Customer who requested an Order containing Products. We set the Serialization Mode in the Linq designer to Unidirectional to enable serialization.
When looking at the code for the Order object, the DataMember attribute is added to all its internal properties such as ID,OrderNumber, etc. and also to the EntitySet of Products, but not to Customer.
One can get around this by manually adding the DataMember attribute to Customer, but this becomes quite cumbersome when there's loads of entities in the database.