AbstractWriteService   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 30
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 0
dl 0
loc 30
ccs 5
cts 5
cp 1
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 6 1
1
<?php
2
/**
3
 * Created by PhpStorm.
4
 * User: davis
5
 * Date: 7/30/17
6
 * Time: 7:21 PM
7
 */
8
9
namespace DavisPeixoto\BlogCore\Service;
10
11
use DavisPeixoto\BlogCore\Entity\AbstractEntity;
12
use DavisPeixoto\BlogCore\Interfaces\RepositoryInterface;
13
use Psr\Log\LoggerInterface;
14
15
/**
16
 * Class AbstractSaveService
17
 * @package DavisPeixoto\BlogCore\Service
18
 */
19
abstract class AbstractWriteService
20
{
21
    /**
22
     * @var RepositoryInterface $repository
23
     */
24
    protected $repository;
25
26
    /**
27
     * @var AbstractEntity $entity
28
     */
29
    protected $entity;
30
31
    /**
32
     * @var LoggerInterface $logger
33
     */
34
    protected $logger;
35
36
    /**
37
     * AbstractWriteService constructor.
38
     * @param RepositoryInterface $repository
39
     * @param AbstractEntity $entity
40
     * @param LoggerInterface $logger
41
     */
42 28
    public function __construct(RepositoryInterface $repository, AbstractEntity $entity, LoggerInterface $logger)
43
    {
44 28
        $this->repository = $repository;
45 28
        $this->entity = $entity;
46 28
        $this->logger = $logger;
47 28
    }
48
}
49