Completed
Push — master ( b416d7...51a9f1 )
by Filipe
02:48
created

EntityRemoved::getCollection()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 1
Bugs 0 Features 1
Metric Value
c 1
b 0
f 1
dl 0
loc 4
ccs 0
cts 2
cp 0
rs 10
cc 1
eloc 2
nc 1
nop 0
crap 2
1
<?php
2
3
/**
4
 * This file is part of slick/orm package
5
 *
6
 * For the full copyright and license information, please view the LICENSE
7
 * file that was distributed with this source code.
8
 */
9
10
namespace Slick\Orm\Event;
11
12
use Slick\Orm\Entity\EntityCollectionInterface;
13
14
/**
15
 * Entity Removed event
16
 * 
17
 * @package Slick\Orm\Event
18
 * @author  Filipe Silva <[email protected]>
19
 */
20
class EntityRemoved extends AbstractEvent implements EventInterface
21
{
22
23
    const ACTION_REMOVE = 'entity.removed';
24
25
    /**
26
     * @var string
27
     */
28
    protected $name = 'EntityRemoved';
29
30
    /**
31
     * @var string
32
     */
33
    protected $action = self::ACTION_REMOVE;
34
35
    /**
36
     * Gets the entity collection that triggers the event
37
     *
38
     * @return EntityCollectionInterface
39
     */
40
    public function getCollection()
41
    {
42
        return $this->params['collection'];
43
    }
44
}