Note that there are some explanatory texts on larger screens.

plurals
  1. POIs it possible to use NHibernate without altering a DDD model that is part of a framework
    primarykey
    data
    text
    <p>I dig a lot of things about the <strong>DDD approach</strong> (Ubiquitous language, Aggregates, Repositories, etc.) and I think that, contrary to what I read a lot, entities should have behavior rather then being agnostic. All examples I see tend to present entities with <strong>virtual automatic properties</strong> and an <strong>empty constructor</strong> (protected or worst, public) and that's it. I consider this kind of objects more like DTOs then entities.</p> <p>I'm in the process of <strong>creating a framework</strong> with its specific API and I don't want to be <strong>tied to an ORM</strong>. So I built the domain first (without thinking of persistence) and now I would like to use NHibernate as persistence tool so I added a new project to my current solution to help ensure that my model isn't altered to support NHibernate. This project should be an implementation of the abstract repositories that live inside my domain. And now the difficulties arise.</p> <p>Since <strong>it is my first time with NHibernate</strong> (I'm also trying Fluent Nhibernate but it seems even more restricting) I would like to know :</p> <ol> <li>Is it possible to use NHibernate without altering a DDD model that is part of a framework</li> <li>The things (constraints) that are necessary for NHibernate to work as expected and efficiently (virtual properties, empty constructors, etc.) I think this list would be helpful to a lot of people who are starting to learn NHibernate.</li> </ol> <p>Please keep in mind that I'm building a framework so the <a href="http://en.wikipedia.org/wiki/Open/closed_principle" rel="nofollow noreferrer">Open/Closed Principle</a> is very important for me.</p> <p>P.S.: Sorry if my english is not good, I'm from Montreal and I speak french.</p> <p><strong>Edit 1:</strong> Here is one problem I have with NHibernate now - <a href="https://stackoverflow.com/questions/1516752/how-to-map-type-with-fluent-nhibernate">How to map Type with Nhibernate (and Fluent NHibernate)</a></p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload