This is a migrated thread and some comments may be shown as answers.

[Solved] Fluent mapping and enhancer

1 Answer 144 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
David
Top achievements
Rank 1
David asked on 31 Dec 2010, 09:34 PM

Hello

Just curious. Suppose I have an assembly A which has all the entities and mappings using fluent api. this assembly needs enhancing, I get it. but what happens to the assembly which is using assembly A. does it need enhancing too? 

thanks

UPDATE
________________

Is fluent mapping api the only way to work with code only approach? I mean I already have business objects, and I want to make them persistent, fluent api is the only solution? or is it possible to decorate the objects with attributes or map it through xml like nhibernate does? 

1 Answer, 1 is accepted

Sort by
0
Accepted
Serge
Telerik team
answered on 03 Jan 2011, 11:13 AM
Hi David,

 You are correct only the project containing the entities and the mapping should be enhanced. I would like to mention that a lot of people are making the mistake of moving the class deriving from FluentMetadataSource to a different project which is incorrect as this class is used during enhancement. 

The rule is that you need both all entities and the metadata source in the project you mapping is, this means that you can implement your context class in another project. Be sure to check out our documentation on the matter if you haven't already. 

At the moment this is the only way to work with code only. 

Regards,
Serge
the Telerik team
Accelerate your learning with industry's first Telerik OpenAccess ORM SDK. Download today.
Tags
General Discussions
Asked by
David
Top achievements
Rank 1
Answers by
Serge
Telerik team
Share this question
or