0

We are planning to developing a software following Domain Driven Design inspiring by the Red (EE) and Blue (VV) ddd books. The business is not that complicated. It is possible to avoid inheritances for all concrete classes. The goal is to feel the importance of Domain Model. So is it OK to use POCO classes which will be inherited from Entity? Or It will be better to create the domain model and use DTO or repository to transfer values to domain model?

MJK
  • 3,434
  • 3
  • 32
  • 55
  • I would focus on the model first. It's not about the code at this point. Getting to grips with a model is a visual & verbal activity with code probes to verify how the model translates to code. – Yves Reynhout Jul 10 '14 at 10:21
  • Basically, my question was when should the designer decide to go for anemic domain model? – MJK Jul 10 '14 at 10:51
  • Not sure what you mean by that, but "a POCO class inherited from Entity" might be an oxymoron. What Entity are you talking about ? – guillaume31 Jul 10 '14 at 12:17
  • I was thinking about domain entity. "abstract class EntityWithCompositeId : Entity" – MJK Jul 11 '14 at 08:45

1 Answers1

0

If your goal is to "experience" DDD, then you should probably create domain objects instead of relying on Entities.

This is especially true if you are looking to extend any learnings from this process into other code bases that are more complex and can't take this shortcut.

Rob Conklin
  • 8,806
  • 1
  • 19
  • 23