Repository pattern

This commit is contained in:
andrewnester
2014-03-12 13:11:49 +03:00
parent b0b0d4a1a4
commit a0c2a7d638
5 changed files with 304 additions and 0 deletions

12
Repository/README.md Normal file
View File

@@ -0,0 +1,12 @@
# Repository
## Purpose
Mediates between the domain and data mapping layers using a collection-like interface for accessing domain objects.
Repository encapsulates the set of objects persisted in a data store and the operations performed over them, providing a more object-oriented view of the persistence layer.
Repository also supports the objective of achieving a clean separation and one-way dependency between the domain and data mapping layers.
## Examples
* Doctrine 2 ORM: there is Repository that mediates between Entity and DBAL and contains methods to retrieve objects
* Laravel Framework