ConfigureActionEvent::getOptionsResolver()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %
Metric Value
dl 0
loc 4
rs 10
cc 1
eloc 2
nc 1
nop 0
1
<?php
2
3
namespace Pim\Bundle\CustomEntityBundle\Event;
4
5
use Pim\Bundle\CustomEntityBundle\Action\ActionInterface;
6
use Symfony\Component\OptionsResolver\OptionsResolver;
7
8
/**
9
 * Event for action configuration
10
 *
11
 * @author    Antoine Guigan <[email protected]>
12
 * @copyright 2013 Akeneo SAS (http://www.akeneo.com)
13
 * @license   http://opensource.org/licenses/osl-3.0.php  Open Software License (OSL 3.0)
14
 */
15
class ConfigureActionEvent extends ActionEvent
16
{
17
    /**
18
     * @var OptionsResolver
19
     */
20
    protected $optionsResolver;
21
22
    /**
23
     * @param ActionInterface $action
24
     * @param OptionsResolver $optionsResolver
25
     */
26
    public function __construct(ActionInterface $action, OptionsResolver $optionsResolver)
27
    {
28
        parent::__construct($action);
29
        $this->optionsResolver = $optionsResolver;
30
    }
31
32
    /**
33
     * Returns the options resolver for the action
34
     *
35
     * @return OptionsResolver
36
     */
37
    public function getOptionsResolver()
38
    {
39
        return $this->optionsResolver;
40
    }
41
}
42