Passed
Push — master ( 727475...c2e18b )
by Igor
04:07
created

LawFormation::setEmail()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 3
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 2
nc 1
nop 1
dl 0
loc 5
ccs 3
cts 3
cp 1
crap 1
rs 10
c 1
b 0
f 0
1
<?php
2
3
namespace SomeWork\Minjust\Entity;
4
5
/**
6
 * @see \SomeWork\Minjust\Tests\Unit\Entity\LawFormationTest
7
 */
8
class LawFormation
9
{
10
    /**
11
     * @var string
12
     */
13
    protected $organizationalForm = '';
14
15
    /**
16
     * @var string
17
     */
18
    protected $name = '';
19
20
    /**
21
     * @var string
22
     */
23
    protected $address = '';
24
25
    /**
26
     * @var string
27
     */
28
    protected $phone = '';
29
30
    /**
31
     * @var string
32
     */
33
    protected $email = '';
34
35
    /**
36
     * @return string
37
     */
38 1
    public function getOrganizationalForm(): string
39
    {
40 1
        return $this->organizationalForm ?: '';
41
    }
42
43
    /**
44
     * @param string $organizationalForm
45
     *
46
     * @return LawFormation
47
     */
48 1
    public function setOrganizationalForm(string $organizationalForm): LawFormation
49
    {
50 1
        $this->organizationalForm = $organizationalForm;
51
52 1
        return $this;
53
    }
54
55
    /**
56
     * @return string
57
     */
58 1
    public function getName(): string
59
    {
60 1
        return $this->name ?: '';
61
    }
62
63
    /**
64
     * @param string $name
65
     *
66
     * @return LawFormation
67
     */
68 1
    public function setName(string $name): LawFormation
69
    {
70 1
        $this->name = $name;
71
72 1
        return $this;
73
    }
74
75
    /**
76
     * @return string
77
     */
78 1
    public function getAddress(): string
79
    {
80 1
        return $this->address ?: '';
81
    }
82
83
    /**
84
     * @param string $address
85
     *
86
     * @return LawFormation
87
     */
88 1
    public function setAddress(string $address): LawFormation
89
    {
90 1
        $this->address = $address;
91
92 1
        return $this;
93
    }
94
95
    /**
96
     * @return string
97
     */
98 1
    public function getPhone(): string
99
    {
100 1
        return $this->phone ?: '';
101
    }
102
103
    /**
104
     * @param string $phone
105
     *
106
     * @return LawFormation
107
     */
108 1
    public function setPhone(string $phone): LawFormation
109
    {
110 1
        $this->phone = $phone;
111
112 1
        return $this;
113
    }
114
115
    /**
116
     * @return string
117
     */
118 1
    public function getEmail(): string
119
    {
120 1
        return $this->email ?: '';
121
    }
122
123
    /**
124
     * @param string $email
125
     *
126
     * @return LawFormation
127
     */
128 1
    public function setEmail(string $email): LawFormation
129
    {
130 1
        $this->email = $email;
131
132 1
        return $this;
133
    }
134
}
135