Completed
Push — master ( df1f12...4872e5 )
by Lucas
05:42
created

PersonContact::getProtocol()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1
Metric Value
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
cc 1
eloc 2
nc 1
nop 0
crap 1
1
<?php
2
/**
3
 * Graviton\PersonBundle\Document\PersonContact
4
 */
5
6
namespace Graviton\PersonBundle\Document;
7
8
/**
9
 * Graviton\PersonBundle\Document\PersonContact
10
 *
11
 * @author   List of contributors <https://github.com/libgraviton/graviton/graphs/contributors>
12
 * @license  http://opensource.org/licenses/gpl-license.php GNU Public License
13
 * @link     http://swisscom.ch
14
 */
15
class PersonContact
16
{
17
    /**
18
     * @var MongoId $id
19
     */
20
    protected $id;
21
22
    /**
23
     * @var string $type
24
     */
25
    protected $type;
26
27
    /**
28
     * @var string $ri
29
     */
30
    protected $value;
31
32
    /**
33
     * @var string $protocol
34
     */
35
    protected $protocol;
36
37
    /**
38
     * @var string $uri
39
     */
40
    protected $uri;
41
42
    /**
43
     * Get id
44
     *
45
     * @return id $id
0 ignored issues
show
Documentation introduced by
Should the return type not be MongoId?

This check compares the return type specified in the @return annotation of a function or method doc comment with the types returned by the function and raises an issue if they mismatch.

Loading history...
46
     */
47 25
    public function getId()
48
    {
49 25
        return $this->id;
50
    }
51
52
    /**
53
     * Set type
54
     *
55
     * @param string $type type of contact (ie. phone, email, web, xmpp)
56
     *
57
     * @return self
58
     */
59 24
    public function setType($type)
60
    {
61 24
        $this->type = $type;
62
63 24
        return $this;
64
    }
65
66
    /**
67
     * Get type
68
     *
69
     * @return string $type
70
     */
71 25
    public function getType()
72
    {
73 25
        return $this->type;
74
    }
75
76
    /**
77
     * Set value
78
     *
79
     * @param string $value value to contact resource (starting with tel:, http:, ...)
80
     *
81
     * @return self
82
     */
83 23
    public function setValue($value)
84
    {
85 23
        $this->value = $value;
86
87 23
        return $this;
88
    }
89
90
    /**
91
     * Get value
92
     *
93
     * @return string $value
94
     */
95 25
    public function getValue()
96
    {
97 25
        return $this->value;
98
    }
99
100
    /**
101
     * Set protocol
102
     *
103
     * @param string $protocol protocol
104
     *
105
     * @return self
106
     */
107 23
    public function setProtocol($protocol)
108
    {
109 23
        $this->protocol = $protocol;
110
111 23
        return $this;
112
    }
113
114
    /**
115
     * Get protocol
116
     *
117
     * @return string $protocol
118
     */
119 25
    public function getProtocol()
120
    {
121 25
        return $this->protocol;
122
    }
123
124
    /**
125
     * Set uri
126
     *
127
     * @param string $uri uri
128
     *
129
     * @return self
130
     */
131 23
    public function setUri($uri)
132
    {
133 23
         $this->uri = $uri;
134
135 23
         return $this;
136
    }
137
138
    /**
139
     * Get uri
140
     *
141
     * @return string $uri
142
     */
143 25
    public function getUri()
144
    {
145 25
        return $this->uri;
146
    }
147
}
148