Product   A
last analyzed

Complexity

Total Complexity 5

Size/Duplication

Total Lines 41
Duplicated Lines 0 %

Test Coverage

Coverage 0%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 17
c 1
b 0
f 0
dl 0
loc 41
rs 10
ccs 0
cts 12
cp 0
wmc 5

5 Methods

Rating   Name   Duplication   Size   Complexity  
A getValue() 0 3 1
A getName() 0 3 1
A setValue() 0 5 1
A getId() 0 3 1
A setName() 0 5 1
1
<?php
2
3
namespace App\Entity;
4
5
use App\Repository\ProductRepository;
6
use Doctrine\ORM\Mapping as ORM;
7
8
#[ORM\Entity(repositoryClass: ProductRepository::class)]
9
class Product
10
{
11
    #[ORM\Id]
12
    #[ORM\GeneratedValue]
13
    #[ORM\Column]
14
    private ?int $id = null;
15
16
    #[ORM\Column(length: 255)]
17
    private ?string $name = null;
18
19
    #[ORM\Column]
20
    private ?int $value = null;
21
22
    public function getId(): ?int
23
    {
24
        return $this->id;
25
    }
26
27
    public function getName(): ?string
28
    {
29
        return $this->name;
30
    }
31
32
    public function setName(string $name): static
33
    {
34
        $this->name = $name;
35
36
        return $this;
37
    }
38
39
    public function getValue(): ?int
40
    {
41
        return $this->value;
42
    }
43
44
    public function setValue(int $value): static
45
    {
46
        $this->value = $value;
47
48
        return $this;
49
    }
50
}
51