Question about domain models & their visibility...
Posted
by Another SO User
on Stack Overflow
See other posts from Stack Overflow
or by Another SO User
Published on 2010-05-05T03:11:46Z
Indexed on
2010/05/05
3:18 UTC
Read the original article
Hit count: 225
I was involved in an interesting debate about the visibility of domain models & was wondering if people here have any good guidance.
- Per my understanding of MDA, we need not expose the domain model throughout the application layers & tiers
- The reason being that any change to the domain model has an impact in the overall application
- The wise thing to do would be to expose light-weight object (DTO's) which are a small sub-set of the domain model to abstract the actual model
- On the flip side, any change to the domain model would mean changing various DTO's throughout the application for the change to be visible, while if we do expose the domain model, then the change is in a single location
Hope to see some comments & thoughts about this.
Appreciate all the help!
© Stack Overflow or respective owner