ORMPersistentCommandRepository::get()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 1
eloc 2
nc 1
nop 1
1
<?php
2
3
declare (strict_types = 1);
4
5
namespace HMLB\DDDBundle\Doctrine\ORM;
6
7
use HMLB\DDD\Entity\Identity;
8
use HMLB\DDD\Message\Command\PersistentCommand;
9
use HMLB\DDDBundle\Repository\PersistentCommandRepository;
10
11
/**
12
 * ORMCommandRepository.
13
 *
14
 * @author Hugues Maignol <[email protected]>
15
 */
16
class ORMPersistentCommandRepository extends AbstractOrmPersistentMessageRepository implements PersistentCommandRepository
17
{
18
    /**
19
     * @param Identity $identity
20
     *
21
     * @return PersistentCommand
22
     */
23
    public function get(Identity $identity)
24
    {
25
        return $this->em->getRepository(PersistentCommand::class)->find($identity);
26
    }
27
}
28