Completed
Pull Request — master (#602)
by Tom
07:01
created

Category   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 34
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

Changes 0
Metric Value
wmc 3
lcom 0
cbo 0
dl 0
loc 34
rs 10
c 0
b 0
f 0
1
<?php
2
3
declare(strict_types=1);
4
5
namespace DoctrineORMModuleTest\Assets\Entity;
6
7
use Doctrine\ORM\Mapping as ORM;
8
9
/**
10
 * @ORM\Entity
11
 * @ORM\Table(name="doctrine_orm_module_category")
12
 */
13
class Category
14
{
15
    /**
16
     * @ORM\Id
17
     * @ORM\Column(type="integer");
18
     * @ORM\GeneratedValue(strategy="AUTO")
19
     */
20
    protected ?int $id;
0 ignored issues
show
Bug introduced by
This code did not parse for me. Apparently, there is an error somewhere around this line:

Syntax error, unexpected '?', expecting T_FUNCTION or T_CONST
Loading history...
21
22
    /** @ORM\Column(type="string", nullable=true) */
23
    protected string $name;
24
25
    public function getId() : ?int
26
    {
27
        return $this->id;
28
    }
29
30
    public function setName(string $name) : self
31
    {
32
        $this->name = $name;
33
34
        return $this;
35
    }
36
37
    public function getName() : string
38
    {
39
        return $this->name;
40
    }
41
}
42