Brief description
Package data model and data access details in the relevant domain object implementation. Active domain objects allow application code to avoid any direct interaction with the database.
Active is that the domain object is not just a simple representation of data, and the logical operation (initialization, refresh, saving, list) is also disclosed, which completed most related database interactions for their data. Operation names are named using the domain.
applicability
The complexity of physical data models and data access is required to be hidden in application logic.
All data models and data access details on a certain domain concept are packaged in a single component.
The inconsistency and 涩性 性 - of the application logic hide the data model - the advice of legacy data.
advantage
Clear application code
Decoupling application code and data model
Tissue related data access code into a single component
Disadvantage
Data Access distribution in multiple domain objects
Limited the application of application on data access