Entity classes were not generated in NHibernate Fluent Model

Discussion of open issues, suggestions and bugs regarding Entity Developer - ORM modeling and code generation tool
Post Reply
Posts: 1
Joined: Sun 04 Sep 2011 19:06

Entity classes were not generated in NHibernate Fluent Model

Post by aflo » Sun 04 Sep 2011 20:07

I have the trial version of Entity Dev.
When I generate a NHibernate model the entity classes were not generated when I use the fluent mapping. Only the mapping classes were generated. It works when I use the NHibernate template.

For instance the class
public class EmployeeMap : ClassMap
is generated not not the class Employee.

What can I do?

Site Admin
Posts: 8247
Joined: Thu 14 Aug 2008 12:44

Post by Shalex » Mon 05 Sep 2011 13:56

To generate files for entity classes and mapping you have to add both templates to your model. For example:
- create a model using Create Model Wizard and choose the Fluent NHibernate template on the 'Choose Code Generation Template' page
- add the NHibernate template to the model (see the Templates node in the Model Explorer tool window)
- set the 'Generate Xml Mapping' property of the NHibernate template to false
- run code generation

We will add this information to our documentation to avoid such kind of misunderstanding.

Post Reply