Reputation: 12424
I am building a .NET 4.5 C# Web API RESTful solution and I would like someone to tell me if my project solution is correct and/or wise(-enough?) for a solution designed using Domain Driven Design, please.
The solution has been split into 6 projects:
The web project and forms the interface between the solution and the outside world. Contains the Web API controllers. Contains almost no logic beyond gathering values from request objects and asking the BizApi layer for work.
Provides the domain services and allows the /Base interface project to have access to the domain business logic objects in the /Biz.Domain project.
Provides the domain classes for the Biz.Api layer. These provide methods to manipulate the data of the business in memory.
The database repository layer. Accesses the databases and maps returned data into internal DTO's defined in the /Interfaces layer.
Provides a proxy layer to external dependencies like web services and maps their returned data to internal DTOs defined in the /Interfaces project.
Contains the DTO classes for passing data around the solution and the C# interfaces to define contracts for things like IoC.
Upvotes: 1
Views: 2215
Reputation: 559
See http://dddcommunity.org/examples2 for a sample DDD app - you can perhaps get some ideas from its Visual Studio structure.
Upvotes: 1