Passed
Push — master ( c7459e...5c3821 )
by Arthur
22:05
created

FileGeneratedEvent   A

Complexity

Total Complexity 5

Size/Duplication

Total Lines 67
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
eloc 13
dl 0
loc 67
ccs 11
cts 11
cp 1
rs 10
c 0
b 0
f 0
wmc 5

5 Methods

Rating   Name   Duplication   Size   Complexity  
A getFilePath() 0 3 1
A getGenerationClass() 0 3 1
A __construct() 0 6 1
A getStubOptions() 0 3 1
A getStubName() 0 3 1
1
<?php
2
/**
3
 * Created by PhpStorm.
4
 * User: arthur
5
 * Date: 10.03.19
6
 * Time: 20:15
7
 */
8
9
namespace Foundation\Generator\Events;
10
11
12
use Foundation\Abstracts\Events\Event;
13
14
/**
15
 * Class FileGeneratedEvent
16
 * @package Foundation\Generator\Events
17
 */
18
final class FileGeneratedEvent extends Event
19
{
20
    /**
21
     * @var string
22
     */
23
    protected $filePath;
24
25
    /**
26
     * @var string
27
     */
28
    protected $stubName;
29
30
    /**
31
     * @var array
32
     */
33
    protected $stubOptions;
34
35
    /**
36
     * @var string
37
     */
38
    protected $generationClass;
39
40
    /**
41 12
     * FileGeneratedEvent constructor.
42
     * @param string $filePath
43 12
     * @param string $stubName
44 12
     * @param array $stubOptions
45 12
     * @param string $generationClass
46 12
     */
47
    public function __construct(string $filePath, string $stubName, array $stubOptions, string $generationClass)
48
    {
49
        $this->filePath = $filePath;
50
        $this->stubName = $stubName;
51 9
        $this->stubOptions = $stubOptions;
52
        $this->generationClass = $generationClass;
53 9
    }
54
55
    /**
56
     * @return string
57
     */
58
    public function getFilePath(): string
59 12
    {
60
        return $this->filePath;
61 12
    }
62
63
    /**
64
     * @return string
65
     */
66
    public function getStubName(): string
67 9
    {
68
        return $this->stubName;
69 9
    }
70
71
    /**
72
     * @return array
73
     */
74
    public function getStubOptions(): array
75
    {
76
        return $this->stubOptions;
77
    }
78
79
    /**
80
     * @return string
81
     */
82
    public function getGenerationClass(): string
83
    {
84
        return $this->generationClass;
85
    }
86
87
88
}
89