Smart Domain Pattern 的核心思想和适用场景是什么?


  • Object-Oriented Approach(No service)
  • Model as fully connected object graph (Not disconnected aggreation)
  • Direcly map to restful API(with HATEOAS)
  • Act as an absracion layer to hide implentation details
  • Consistent between conceptual model / model / api

Entity is not about value,but about identity and association。
Can be mapped easily as s lossess representation model
Association is as abstraction mechanism for connections
Association is as abstraction mechanism for lifecycle
Pasted image 20250129182130
kenk back CRC 法

Restful 不是关于 get put put post,而是学习了互联网架构模式(数据表达行为),和面向对象本书数据抽象行为一致