All Questions

43
votes
5answers
16219 views

EF codefirst : Should I initialize navigation properties?

I had seen some books(e.g programming entity framework code first Julia Lerman) define their domain classes (POCO) with no initialization of the navigation properties like: public class User { pu...
7
votes
4answers
797 views

Making Entity Class Closed for Changes

I have a database relationship as shown below. The domain objects are created based on LINQ to SQL ORM. A payment comprises of Cash Payment and Gift Coupon Payments. Suppose the total amount of pu...
16
votes
2answers
3003 views

Who should handle the conditions in complex queries, the data mapper or the service layer?

this question did a very good job of clearing my confusion a bit on the matter, but I'm having a hard time finding reliable sources on what the exact limitations of the service layer should be. For t...
178
votes
6answers
41332 views

Domain Driven Design: Domain Service, Application Service

Can someone explain the difference between domain and application services by providing some examples? And, if a service is a domain service, would I put the actual implementation of this service with...
35
votes
3answers
12834 views

What are the benefits of Persistence Ignorance?

I am a newbie in the DDD+TDD World. But I have been in programming for almost 9 years. Can someone please explain me the benefits of persistance ignornace ? Typical nHibernate application just pushes...
25
votes
5answers
6428 views

Is it ok for entities to access repositories?

I've just started working with DDD, so maybe this is a silly question... Is it ok for an entity to access a repository (via some IRepository interface) to get a value at runtime? For example, I want...
273
votes
8answers
89442 views

What is the difference between DAO and Repository patterns?

What is the difference between Data Access Objects (DAO) and Repository patterns? I am developing an application using Enterprise Java Beans (EJB3), Hibernate ORM as infrastructure, and Domain-Driven ...
2
votes
2answers
545 views

Persist Data by Programming Against Interface

I have a IBankAccount interface that I will be passing to the ApplicationService. The changes made on the account objects (in the ApplicationService project) need to be persisted in the database. The ...
291
votes
8answers
115809 views

Good Domain Driven Design samples

I'm learning about Domain Driven Design and enjoying every minute of it. However, there are some practical issues that are confusing to me that I think seeing some good samples might clear up. So bei...
10
votes
2answers
4327 views

How to remove unit of work functionality from repositories using IOC

I have an application using ASP.NET MVC, Unity, and Linq to SQL. The unity container registers the type AcmeDataContext which inherits from System.Data.Linq.DataContext, with a LifetimeManager using ...

Previous Next