Completed
Push — master ( 530f3a...b8358f )
by Siim
10:54
created

EntitymanagerTrait::setEntityManager()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 1
nc 1
nop 1
dl 0
loc 3
rs 10
c 0
b 0
f 0
1
<?php
2
/**
3
 * Created by PhpStorm.
4
 * User: siim
5
 * Date: 4.02.19
6
 * Time: 11:08
7
 */
8
9
namespace Sf4\Api\Utils\Traits;
10
11
use Doctrine\ORM\EntityManagerInterface;
12
13
trait EntitymanagerTrait
14
{
15
16
    /** @var EntityManagerInterface $entityManager */
17
    protected $entityManager;
18
19
    /**
20
     * @return EntityManagerInterface
21
     */
22
    public function getEntityManager(): EntityManagerInterface
23
    {
24
        return $this->entityManager;
25
    }
26
27
    /**
28
     * @param EntityManagerInterface $entityManager
29
     */
30
    public function setEntityManager(EntityManagerInterface $entityManager): void
31
    {
32
        $this->entityManager = $entityManager;
33
    }
34
35
}
36