Completed
Push — master ( 1ee05e...99144a )
by Gaetano
05:13
created

MigrationSuspendedEvent::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5

Duplication

Lines 5
Ratio 100 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
dl 5
loc 5
ccs 0
cts 5
cp 0
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 2
crap 2
1
<?php
2
3
namespace Kaliop\eZMigrationBundle\API\Event;
4
5
use Symfony\Component\EventDispatcher\Event;
6
use Kaliop\eZMigrationBundle\API\Value\MigrationStep;
7
use Kaliop\eZMigrationBundle\API\Exception\MigrationSuspendedException;
8
9 View Code Duplication
class MigrationSuspendedEvent extends Event
0 ignored issues
show
Duplication introduced by
This class seems to be duplicated in your project.

Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.

You can also find more detailed suggestions in the “Code” section of your repository.

Loading history...
10
{
11
    protected $step;
12
    protected $exception;
13
14
    public function __construct(MigrationStep $step, MigrationSuspendedException $exception)
15
    {
16
        $this->step = $step;
17
        $this->exception = $exception;
18
    }
19
20
    /**
21
     * @return MigrationStep
22
     */
23
    public function getStep()
24
    {
25
        return $this->step;
26
    }
27
28
    /**
29
     * @return MigrationSuspendedException
30
     */
31
    public function getException()
32
    {
33
        return $this->exception;
34
    }
35
}
36