Passed
Push — master ( 451245...2b5fd7 )
by Brent
03:56
created

Event::getData()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 2
nc 1
nop 0
dl 0
loc 3
rs 10
c 0
b 0
f 0
1
<?php
2
3
namespace Brendt\Stitcher\Event;
4
5
use \Symfony\Component\EventDispatcher\Event as SymfonyEvent;
6
7
class Event extends SymfonyEvent
8
{
9
    private $data;
10
11
    /**
12
     * Event constructor.
13
     *
14
     * @param array $data
15
     */
16
    public function __construct($data = []) {
17
        $this->data = $data;
18
    }
19
20
    /**
21
     * @param array $data
22
     *
23
     * @return Event
24
     */
25
    public static function create($data = []) : Event {
26
        return new self($data);
27
    }
28
29
    public function getData() {
30
        return $this->data;
31
    }
32
33
}
34