demo
demo copied to clipboard
Create interfaces for repositories
I think it is good practice to use interfaces for repositories.
Repository methods already return DataReaderInterface objects (this gives us independence from DBAL), it remains only to describe their API in the interfaces.
Do you mean a common interface or repository-specific interfaces?
Common interface with ooerations more used, created, modify, delete, find, etc.
Do you mean a common interface or repository-specific interfaces?
It is good to have a common interface in the context of ORM and other common cases. However in the context of this repository i mean only repository-specific interfaces.
- Who would be users/clients of these interfaces?
- Would these interfaces separate system boundaries?
- Would there be multiple implementations of these interfaces?