Delete   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 39
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 1

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 3
lcom 1
cbo 1
dl 0
loc 39
c 0
b 0
f 0
ccs 7
cts 7
cp 1
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
A getDestPath() 0 4 1
A setDestPath() 0 4 1
A getMessageSuccess() 0 4 1
1
<?php
2
namespace AppBundle\Sync\Entity\Task;
3
4
use AppBundle\Sync\Entity\Task;
5
6
/**
7
 * "Delete" task
8
 *
9
 * @author Sergey Sadovoi <[email protected]>
10
 */
11
class Delete extends Task
12
{
13
    /**
14
     * {@inheritdoc}
15
     */
16
    protected $name = 'delete';
17
    /**
18
     * @var string  Dest path
19
     */
20
    protected $destPath;
21
22
    /**
23
     * Get dest path
24
     *
25
     * @return string
26
     */
27 2
    public function getDestPath()
28
    {
29 2
        return $this->destPath;
30
    }
31
32
    /**
33
     * Set dest path
34
     *
35
     * @param string $destPath
36
     */
37 2
    public function setDestPath($destPath)
38
    {
39 2
        $this->destPath = $destPath;
40 2
    }
41
42
    /**
43
     * {@inheritdoc}
44
     */
45 2
    public function getMessageSuccess()
46
    {
47 2
        return sprintf('Deleted %s', basename($this->getDestPath()));
48
    }
49
}
50