Completed
Branch dev (a083dd)
by Arnaud
03:08
created

AdminEvent::setAdmin()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 6
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 3
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 6
ccs 3
cts 3
cp 1
rs 9.4285
cc 1
eloc 3
nc 1
nop 1
crap 1
1
<?php
2
3
namespace LAG\AdminBundle\Event;
4
5
use LAG\AdminBundle\Admin\AdminInterface;
6
use Symfony\Component\EventDispatcher\Event;
7
8
class AdminEvent extends Event
9
{
10
    const ADMIN_CREATE = 'event.admin.create';
11
    const ACTION_CREATE = 'event.action.create';
12
13
    protected $configuration;
14
15
    /**
16
     * @var AdminInterface
17
     */
18
    protected $admin;
19
20
    /**
21
     * @var string
22
     */
23
    protected $actionName;
24
25
    /**
26
     * @param array $configuration
27
     * @return AdminEvent
28
     */
29 6
    public function setConfiguration(array $configuration)
30
    {
31 6
        $this->configuration = $configuration;
32
33 6
        return $this;
34
    }
35
36
    /**
37
     * @return array
38
     */
39 6
    public function getConfiguration()
40
    {
41 6
        return $this->configuration;
42
    }
43
44
    /**
45
     * @return AdminInterface
46
     */
47
    public function getAdmin()
48
    {
49
        return $this->admin;
50
    }
51
52
    /**
53
     * @param AdminInterface $admin
54
     * @return $this
55
     */
56 5
    public function setAdmin($admin)
57
    {
58 5
        $this->admin = $admin;
59
60 5
        return $this;
61
    }
62
63
    /**
64
     * @return string
65
     */
66
    public function getActionName()
67
    {
68
        return $this->actionName;
69
    }
70
71
    /**
72
     * @param string $actionName
73
     */
74 5
    public function setActionName($actionName)
75
    {
76 5
        $this->actionName = $actionName;
77 5
    }
78
}
79