1 | <?php |
||
17 | abstract class AbstractIdentifier |
||
18 | { |
||
19 | /** |
||
20 | * @var UuidInterface |
||
21 | */ |
||
22 | protected $id; |
||
23 | |||
24 | /** |
||
25 | * @var boolean |
||
26 | */ |
||
27 | protected $rootDevice; |
||
28 | |||
29 | /** |
||
30 | * @var boolean |
||
31 | */ |
||
32 | protected $device; |
||
33 | |||
34 | /** |
||
35 | * @var boolean; |
||
36 | */ |
||
37 | protected $service; |
||
38 | |||
39 | /** |
||
40 | * @var string |
||
41 | */ |
||
42 | protected $domainName; |
||
43 | |||
44 | /** |
||
45 | * @var string |
||
46 | */ |
||
47 | protected $type; |
||
48 | |||
49 | /** |
||
50 | * @var int |
||
51 | */ |
||
52 | protected $version; |
||
53 | |||
54 | /** |
||
55 | * Get id |
||
56 | * |
||
57 | * @return null|UuidInterface |
||
58 | */ |
||
59 | public function getId() |
||
63 | |||
64 | /** |
||
65 | * Set id |
||
66 | * |
||
67 | * @param UuidInterface $id |
||
68 | * |
||
69 | * @return $this |
||
70 | */ |
||
71 | public function setId(UuidInterface $id) |
||
76 | |||
77 | /** |
||
78 | * Return whether this is a root device |
||
79 | * |
||
80 | * @return boolean |
||
81 | */ |
||
82 | public function isRootDevice() |
||
90 | |||
91 | /** |
||
92 | * Set root device |
||
93 | * |
||
94 | * @param boolean $rootDevice |
||
95 | * |
||
96 | * @return $this |
||
97 | */ |
||
98 | public function setRootDevice($rootDevice) |
||
103 | |||
104 | /** |
||
105 | * Return whether this is a device |
||
106 | * |
||
107 | * @return boolean |
||
108 | */ |
||
109 | public function isDevice() |
||
113 | |||
114 | /** |
||
115 | * Set device |
||
116 | * |
||
117 | * @param boolean $device |
||
118 | * |
||
119 | * @return $this |
||
120 | */ |
||
121 | public function setDevice($device) |
||
126 | |||
127 | /** |
||
128 | * Return whether this is a service |
||
129 | * |
||
130 | * @return boolean |
||
131 | */ |
||
132 | public function isService() |
||
136 | |||
137 | /** |
||
138 | * Set service |
||
139 | * |
||
140 | * @param boolean $service |
||
141 | * |
||
142 | * @return $this |
||
143 | */ |
||
144 | public function setService($service) |
||
149 | |||
150 | /** |
||
151 | * Get domainName |
||
152 | * |
||
153 | * @return string |
||
154 | */ |
||
155 | public function getDomainName() |
||
163 | |||
164 | /** |
||
165 | * Set domainName |
||
166 | * |
||
167 | * @param string $domainName |
||
168 | * |
||
169 | * @return $this |
||
170 | */ |
||
171 | public function setDomainName($domainName) |
||
176 | |||
177 | /** |
||
178 | * Get type |
||
179 | * |
||
180 | * @return string |
||
181 | */ |
||
182 | public function getType() |
||
190 | |||
191 | /** |
||
192 | * Set type |
||
193 | * |
||
194 | * @param string $type |
||
195 | * |
||
196 | * @return $this |
||
197 | */ |
||
198 | public function setType($type) |
||
203 | |||
204 | /** |
||
205 | * Get version |
||
206 | * |
||
207 | * @return int |
||
208 | */ |
||
209 | public function getVersion() |
||
217 | |||
218 | /** |
||
219 | * Set version |
||
220 | * |
||
221 | * @param int $version |
||
222 | * |
||
223 | * @return $this |
||
224 | */ |
||
225 | public function setVersion($version) |
||
230 | |||
231 | /** |
||
232 | * Return this object as a string when the object is used in any string context. |
||
233 | * |
||
234 | * @return string |
||
235 | */ |
||
236 | public function __toString() |
||
240 | |||
241 | /** |
||
242 | * Return this sobject as a string. |
||
243 | * |
||
244 | * @return string |
||
245 | */ |
||
246 | abstract public function toString(); |
||
247 | } |
||
248 |