Completed
Push — master ( 06c1ce...67d37c )
by Jeroen
06:20
created

IndexNodeEvent::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 4
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 5
ccs 4
cts 4
cp 1
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 2
crap 1
1
<?php
2
3
namespace Kunstmaan\NodeSearchBundle\Event;
4
5
use Kunstmaan\NodeBundle\Entity\HasNodeInterface;
6
use Symfony\Component\EventDispatcher\Event;
7
8
class IndexNodeEvent extends Event
0 ignored issues
show
Deprecated Code introduced by
The class Symfony\Component\EventDispatcher\Event has been deprecated with message: since Symfony 4.3, use "Symfony\Contracts\EventDispatcher\Event" instead

This class, trait or interface has been deprecated. The supplier of the file has supplied an explanatory message.

The explanatory message should give you some clue as to whether and when the type will be removed from the class and what other constant to use instead.

Loading history...
9
{
10
    const EVENT_INDEX_NODE = 'kunstmaan_node_search.onIndexNode';
11
12
    /**
13
     * @var array
14
     */
15
    public $doc;
16
17
    /**
18
     * @var HasNodeInterface
19
     */
20
    private $page;
21
22 1
    public function __construct(HasNodeInterface $page, array $doc)
23
    {
24 1
        $this->doc = $doc;
25 1
        $this->page = $page;
26 1
    }
27
28
    /**
29
     * @return HasNodeInterface
30
     */
31 1
    public function getPage()
32
    {
33 1
        return $this->page;
34
    }
35
}
36