Entity Translation for Complex Types

Topics: General Discussion Forum, July and December Releases Forum, Service Factory Modeling Edition Forum
Jul 17, 2009 at 10:39 PM

Team;

I searched through the entire discussion list and I couldnt find an answer to this. If it has been discussed please point to me the right thread and my aplogies for not finiding the same.

I am into a project where we are planning to use the WSSF. Implementation technology is going to be WCF and will be using DataContract Serialization.

Right now we have data contracts composed of complex types (aggregated types). Say for example

Class A

{

Property ClassB {get; set;}

Property Class C {get; set}

}

And Class A is exposed to the clients as part of the message contract as well. So inorder to do the business logic implementation we are in need to translating Class A in to its BusinessEnity. The existing translator receipe is wont allow us to map the field since it is of complex type.

Has any one has ideas/suggestions on how to implement a translator for complex types? Or for cases like this we need to create a translator class by hand rather than using the receipe. Or is there any other good design thoughts for cases like this.

 

Thanks

SKR

Jul 18, 2009 at 1:20 AM

Hi SKR,

Here is the pattern for Entity Translator and you may find this and other samples if you search this forum with "Translator" key.

Another usful source for this domain is the Data Access Guidance project.