Applicability
Use the Active Domain Object pattern when:
You want to hide the physical data model and data access complexity from application logic. Doing so keeps application logic cleaner and more focused on the business objects and processes that it models. You want to encapsulate all data model and data access details relating to a single domain concept within a single component. Grouping all accesses to a table or set of related tables makes it easier to predict the effect of and manage data model and data access changes. You want to mask data model inconsistencies or obscurities from application code. Some legacy data models impose less-than-intuitive semantics that you are not at liberty to change. Encapsulating these details within a single component prevents them from polluting application code.
 |