FormRuleProcessorContext   A
last analyzed

Complexity

Total Complexity 4

Size/Duplication

Total Lines 46
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
wmc 4
lcom 0
cbo 0
dl 0
loc 46
ccs 0
cts 11
cp 0
rs 10
c 0
b 0
f 0

4 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 6 1
A getView() 0 4 1
A getForm() 0 4 1
A getConstraints() 0 4 1
1
<?php
2
namespace Boekkooi\Bundle\JqueryValidationBundle\Form;
3
4
use Boekkooi\Bundle\JqueryValidationBundle\Validator\ConstraintCollection;
5
use Symfony\Component\Form\FormInterface;
6
use Symfony\Component\Form\FormView;
7
8
/**
9
 * @author Warnar Boekkooi <[email protected]>
10
 */
11
class FormRuleProcessorContext
12
{
13
    /**
14
     * @var FormView
15
     */
16
    private $view;
17
    /**
18
     * @var FormInterface
19
     */
20
    private $form;
21
    /**
22
     * @var ConstraintCollection
23
     */
24
    private $constraints;
25
26
    public function __construct(FormView $view, FormInterface $form, ConstraintCollection $constraints)
27
    {
28
        $this->view = $view;
29
        $this->form = $form;
30
        $this->constraints = $constraints;
31
    }
32
33
    /**
34
     * @return FormView
35
     */
36
    public function getView()
37
    {
38
        return $this->view;
39
    }
40
41
    /**
42
     * @return FormInterface
43
     */
44
    public function getForm()
45
    {
46
        return $this->form;
47
    }
48
49
    /**
50
     * @return ConstraintCollection
51
     */
52
    public function getConstraints()
53
    {
54
        return $this->constraints;
55
    }
56
}
57