AspectRatio   A
last analyzed

Complexity

Total Complexity 4

Size/Duplication

Total Lines 28
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

Changes 0
Metric Value
wmc 4
lcom 0
cbo 0
dl 0
loc 28
rs 10
c 0
b 0
f 0

4 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 6 1
A getValue() 0 4 1
A getLabel() 0 4 1
A isChecked() 0 4 1
1
<?php
2
3
namespace Presta\ImageBundle\Model;
4
5
class AspectRatio
6
{
7
    private $value;
8
    private $label;
9
    private $checked;
10
11
    public function __construct(?float $value, string $label, bool $checked = false)
12
    {
13
        $this->value = $value;
14
        $this->label = $label;
15
        $this->checked = $checked;
16
    }
17
18
    public function getValue(): ?float
19
    {
20
        return $this->value;
21
    }
22
23
    public function getLabel(): string
24
    {
25
        return $this->label;
26
    }
27
28
    public function isChecked(): bool
29
    {
30
        return $this->checked;
31
    }
32
}
33