Completed
Push — feature/rewrite ( 4d09af...dad4c8 )
by Alexandre
03:40 queued 01:51
created

ReadRepository::find()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
dl 0
loc 4
c 1
b 0
f 0
rs 10
cc 1
eloc 2
nc 1
nop 1
1
<?php
2
3
namespace Black\Page\Infrastructure\Persistence\CQRS;
4
5
use Black\Page\Domain\Model\WebPageId;
6
use Black\Page\Domain\Model\WebPageRepository;
7
8
class ReadRepository
9
{
10
    protected $repository;
11
12
    public function __construct(WebPageRepository $repository)
13
    {
14
        $this->repository = $repository;
15
    }
16
17
    public function find(WebPageId $id)
18
    {
19
        return $this->repository->find($id);
20
    }
21
22
    public function findAll()
23
    {
24
        return $this->repository->findAll();
25
    }
26
}
27