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

Date   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 38
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

Changes 0
Metric Value
wmc 3
lcom 0
cbo 0
dl 0
loc 38
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 DateTime;
8
use Doctrine\ORM\Mapping as ORM;
9
10
/**
11
 * @ORM\Entity
12
 * @ORM\Table(name="doctrine_orm_module_date")
13
 */
14
class Date
15
{
16
    /**
17
     * @ORM\Id
18
     * @ORM\Column(type="integer");
19
     * @ORM\GeneratedValue(strategy="AUTO")
20
     */
21
    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 T_STRING, expecting T_FUNCTION or T_CONST
Loading history...
22
23
    /** @ORM\Column(type="date", nullable=true) */
24
    protected DateTime $date;
25
26
    public function getId() : ?int
27
    {
28
        return $this->id;
29
    }
30
31
    public function setDate(DateTime $date) : void
32
    {
33
        $this->date = $date;
34
    }
35
36
    public function getDate() : DateTime
37
    {
38
        return $this->date;
39
    }
40
}
41