Completed
Push — master ( 334f6b...01d482 )
by Adrien
11:34
created

HasCode::setCode()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 1
nc 1
nop 1
dl 0
loc 3
rs 10
c 0
b 0
f 0
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Application\Traits;
6
7
trait HasCode
8
{
9
    /**
10
     * @var string
11
     *
12
     * @ORM\Column(type="string", length=10, options={"default" = ""})
13
     */
14
    private $code = '';
15
16
    /**
17
     * Set code
18
     *
19
     * @param string $code
20
     */
21
    public function setCode(string $code): void
22
    {
23
        $this->code = $code;
24
    }
25
26
    /**
27
     * Get code
28
     *
29
     * @return string
30
     */
31
    public function getCode(): string
32
    {
33
        return $this->code;
34
    }
35
}
36