How to map class to class data

Topics: General Discussion Forum
Jun 2, 2007 at 1:21 AM
I'm working on a project. This project is not a web service but it does reference one. For the web service I'm connecting to I have a schema. I generated a class from the schema using the xsd.exe tool. I created classes from the SQL tables. I created all the mappings of the classes to the stored procs using the Data Factory included with the WSF. However, I'm not sure if there is a way to map the class created by the xsd.exe tool to a class created by the Data Factory. So what I'm looking for is a class to class data mapping.
Jun 4, 2007 at 10:31 PM
You may try using the translator pattern provided to map the DataContract classes to your busines entities classes. You may find this recipe right clicking a service implementation project and selecting "Create Service Contract Translator" option. In case this may not completly fit your needs, you may take this approach as a starting point to adapt it to your needs.

Charly