Completed
Push — feature/VSVGVQ-7-Entities ( cc0453 )
by Luc
02:51
created

Entity   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 32
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
dl 0
loc 32
rs 10
c 0
b 0
f 0
wmc 3

3 Methods

Rating   Name   Duplication   Size   Complexity  
A setId() 0 3 1
A __construct() 0 3 1
A getId() 0 3 1
1
<?php
2
3
namespace VSV\GVQ_API\Question\Repositories\Entities;
4
5
use Doctrine\ORM\Mapping as ORM;
6
7
/**
8
 * @ORM\MappedSuperclass()
9
 */
10
abstract class Entity
11
{
12
    /**
13
     * @var string
14
     *
15
     * @ORM\Id()
16
     * @ORM\Column(type="string", length=36)
17
     */
18
    private $id;
19
20
    /**
21
     * @param string $id
22
     */
23
    public function __construct(string $id)
24
    {
25
        $this->id = $id;
26
    }
27
28
    /**
29
     * @return string
30
     */
31
    public function getId(): string
32
    {
33
        return $this->id;
34
    }
35
36
    /**
37
     * @param string $id
38
     */
39
    public function setId(string $id): void
40
    {
41
        $this->id = $id;
42
    }
43
}
44