Passed
Pull Request — master (#7641)
by
unknown
09:30
created

CmsProduct   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 30
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 8
dl 0
loc 30
rs 10
c 0
b 0
f 0
wmc 3

3 Methods

Rating   Name   Duplication   Size   Complexity  
A setPrice() 0 3 1
A getPrice() 0 3 1
A getId() 0 3 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Doctrine\Tests\Models\CMS;
6
7
use Doctrine\ORM\Annotation as ORM;
8
9
/**
10
 * CmsProduct
11
 *
12
 * @ORM\Entity
13
 * @ORM\Table(name="cms_products")
14
 */
15
class CmsProduct
16
{
17
    /**
18
     * @ORM\Column(type="integer")
19
     * @ORM\Id @ORM\GeneratedValue
20
     */
21
    public $id;
22
23
    /** @ORM\Column(type="string") */
24
    public $name;
25
26
    /** @ORM\Column(type="decimal") */
27
    public $price;
28
29
    /** @ORM\Column(type="datetime") */
30
    public $created_at;
31
32
    public function getId()
33
    {
34
        return $this->id;
35
    }
36
37
    public function getPrice()
38
    {
39
        return $this->price;
40
    }
41
42
    public function setPrice(float $price)
43
    {
44
        $this->price = $price;
45
    }
46
}
47