Skip to content
Snippets Groups Projects
Verified Commit a7cdb37d authored by Greg0ire's avatar Greg0ire
Browse files

Add slide about fat repositories

parent 33401476
Branches
No related tags found
1 merge request!9Retours ngrekas
......@@ -374,6 +374,22 @@ coup… slide suivant
$repository = $entityManager->getRepository(Article::class);
```
---
## Les repositories, ça peut grossir
```php
interface ArticleRepository
{
public function latestArticles(int size): iterable;
public function mostReadArticles(int size): iterable;
public function mostCommentedArticles(int size): iterable;
public function byTopic(ArticleTopic $topic): iterable;
public function findRelated(Article $article): iterable;
// more and more methods…
}
```
---
## Les Query functions
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment