Domain-Driven Design Quickly 这书很好,
下载地址:http://www.infoq.com/minibooks/domain-driven-design-quickly
判断是否是领域逻辑的原则:就是这个逻辑动作是否有明确的业务上的含义,或者说是否是业务相关的,而不仅仅是技术相关的。
只有将技术实现手段从领域问题中剥离才能保证领域本身的精炼,保证程序员可以把精力集中到领域问题本身上来,而不会满脑子都是技术实现手段。
按照Eric的表述,通常将领域中的组成角色分为以下五种:
实体(Entity):拥有唯一标识的对象。
值对象(Value Object):没有唯一标识的对象。
工厂(Factory):定义创建实体的方法。
仓储(Repository):管理实体的集合并封装其持久化过程。
服务(Service):实现不能指派或封装在一个单一对象上的操作。
a domain model is not a particular diagram; it is the idea that the diagram is intended to
convey.
The previous chapters underscored the importance of an approach to software development that is centered on the business domain.(上一章节强调软件开发方法的重点是以业务领域为中心。)
It is important to choose a model which can be easily and accurately put into code. 选择一种容易且能精确地转化成代码的模型是非常重要的。
A common architectural solution for domain-driven designs contain four conceptual layers:
1.User Interface(Presentation Layer);
2.Application Layer:This is a thin layer which coordinates (调整) the application activity. It does not contain business logic. It does not hold the state of the business objects, but it can hold the state of an application task progress.
3.Domain Layer:This layer contains information about the domain. This is the heart of the business software. The state of business objects is held here. Persistence of the business objects and possibly their state is delegated to the infrastructure layer.
4.Infrastructure Layer :This layer acts as a supporting library for all the other layers. It provides communication between layers, implements persistence for business objects, contains
supporting libraries for the user interface layer, etc.
There are cases when we need to contain some attributes of a domain element. We are not interested in which object it is, but what attributes it has. An object that is used to describe certain aspects of a domain, and which does not have identity, is named Value Object.(有些情况下,领域元素需要包含一些属性。然后我们关注的不是它是哪个对象,而是这个象所拥有的属性。被用来描述一个领域某一方面,而且没有标识的对象叫值对象。)
Value Objects can contain other Value Objects, and they can even contain references to Entities.(值对象中也可包含其他值对象,甚至还可包括对实体的引用。)
分享到:
相关推荐
.NET Domain-driven design with C# sulotion source
关于DDD可参考InfoQ的Mini Book Domain Driven Design Quickly , 还有 Banq 的文章 实战DDD(Domain-Driven Design领域驱动设计), 和 领域模型驱动设计(DDD)之模型提炼 。 本书分为四部分,第一部分讲述了领域模型...
领域驱动,Domain-Driven Design (Tackling Complexity in the Heart of Software,资源来自互联网
domain-driven design
Implementing Domain-Driven Design
The software development community widely acknowledges that domain modeling is central to software design. Through domain modeling, software developers are able to express rich functionality and ...
Domain-Driven Design Distilled. Vaughn Vernon.2016
It offers readers a systematic approach to domain-driven design, presenting an extensive set of design best practices, experience-based techniques, and fundamental principles that facilitate the ...
Domain-Driven Design Distilled DDD(Domain-Driven Design 领域驱动设计)是由Eric Evans最先提出,目的是对软件所涉及到的领域进行建模,以应对系统规模过大时引起的软件复杂性的问题。整个过程大概是这样的,...
Implementing Domain-Driven Design 英文epub 本资源转载自网络,如有侵权,请联系上传者或csdn删除 查看此书详细信息请在美国亚马逊官网搜索此书
Domain-Driven Design领域驱动设计 Domain-Driven Design领域驱动设计
Patterns, Principles And Practices Of Domain-driven Design
Domain-Driven Design in PHP 英文无水印pdf pdf所有页面使用FoxitReader和PDF-XChangeViewer测试都可以打开 本资源转载自网络,如有侵权,请联系上传者或csdn删除 本资源转载自网络,如有侵权,请联系上传者...
Domain Driven Design is a very good book for exper
Patterns, Principles and Practices of Domain-Driven Design 英文无水印pdf pdf所有页面使用FoxitReader和PDF-XChangeViewer测试都可以打开 本资源转载自网络,如有侵权,请联系上传者或csdn删除 本资源转载...
JavaScript Domain-Driven Design allows you to leverage your JavaScript skills to create advanced applications. You'll start with learning domain-driven concepts and working with UML diagrams. You'll ...
Domain-Driven Design - Tackling Complexity in the Heart of Software