Passed
Push — master ( 50332b...6b3eac )
by Dāvis
03:20
created

SpecificationTrait   A

Complexity

Total Complexity 4

Size/Duplication

Total Lines 36
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
dl 0
loc 36
rs 10
c 0
b 0
f 0
wmc 4

4 Methods

Rating   Name   Duplication   Size   Complexity  
A isRequired() 0 3 1
A getName() 0 3 1
A getMessage() 0 3 1
A __construct() 0 4 1
1
<?php
2
3
namespace Sludio\HelperBundle\Openidconnect\Specification;
4
5
trait SpecificationTrait
6
{
7
    /**
8
     * @var string
9
     */
10
    protected $name;
11
12
    /**
13
     * @var string
14
     */
15
    protected $message;
16
17
    /**
18
     * @var bool
19
     */
20
    protected $required;
21
22
    public function __construct($name, $required = false)
23
    {
24
        $this->name = $name;
25
        $this->required = $required;
26
    }
27
28
    public function getName()
29
    {
30
        return $this->name;
31
    }
32
33
    public function getMessage()
34
    {
35
        return $this->message;
36
    }
37
38
    public function isRequired()
39
    {
40
        return $this->required;
41
    }
42
}
43