1
|
|
|
<?php |
2
|
|
|
|
3
|
|
|
declare(strict_types=1); |
4
|
|
|
|
5
|
|
|
namespace Alpha\VisitorTrackingBundle\Entity; |
6
|
|
|
|
7
|
|
|
use Doctrine\ORM\Mapping as ORM; |
8
|
|
|
use Gedmo\Mapping\Annotation as Gedmo; |
9
|
|
|
|
10
|
|
|
/** |
11
|
|
|
* @ORM\Entity |
12
|
|
|
*/ |
13
|
|
|
class Device |
14
|
|
|
{ |
15
|
|
|
/** |
16
|
|
|
* @var int |
17
|
|
|
* |
18
|
|
|
* @ORM\Id |
19
|
|
|
* @ORM\Column(type="integer") |
20
|
|
|
* @ORM\GeneratedValue(strategy="AUTO") |
21
|
|
|
*/ |
22
|
|
|
protected $id; |
23
|
|
|
|
24
|
|
|
/** |
25
|
|
|
* @var Session|null |
26
|
|
|
* |
27
|
|
|
* @ORM\ManyToOne(targetEntity="Session", inversedBy="devices") |
28
|
|
|
* @ORM\JoinColumn(nullable=true) |
29
|
|
|
*/ |
30
|
|
|
protected $session; |
31
|
|
|
|
32
|
|
|
/** |
33
|
|
|
* @var string |
34
|
|
|
* |
35
|
|
|
* @ORM\Column(type="json_array") |
36
|
|
|
*/ |
37
|
|
|
protected $fingerprint; |
38
|
|
|
|
39
|
|
|
/** |
40
|
|
|
* @var string|null |
41
|
|
|
* |
42
|
|
|
* @ORM\Column(type="text", nullable=true) |
43
|
|
|
*/ |
44
|
|
|
protected $canvas; |
45
|
|
|
|
46
|
|
|
/** |
47
|
|
|
* @var string|null |
48
|
|
|
* |
49
|
|
|
* @ORM\Column(type="text", nullable=true) |
50
|
|
|
*/ |
51
|
|
|
protected $fonts; |
52
|
|
|
|
53
|
|
|
/** |
54
|
|
|
* @var string|null |
55
|
|
|
* |
56
|
|
|
* @ORM\Column(type="text", nullable=true) |
57
|
|
|
*/ |
58
|
|
|
protected $navigator; |
59
|
|
|
|
60
|
|
|
/** |
61
|
|
|
* @var string|null |
62
|
|
|
* |
63
|
|
|
* @ORM\Column(type="text", nullable=true) |
64
|
|
|
*/ |
65
|
|
|
protected $plugins; |
66
|
|
|
|
67
|
|
|
/** |
68
|
|
|
* @var string|null |
69
|
|
|
* |
70
|
|
|
* @ORM\Column(type="text", nullable=true) |
71
|
|
|
*/ |
72
|
|
|
protected $screen; |
73
|
|
|
|
74
|
|
|
/** |
75
|
|
|
* @var string|null |
76
|
|
|
* |
77
|
|
|
* @ORM\Column(type="text", nullable=true) |
78
|
|
|
*/ |
79
|
|
|
protected $systemColors; |
80
|
|
|
|
81
|
|
|
/** |
82
|
|
|
* @var string|null |
83
|
|
|
* |
84
|
|
|
* @ORM\Column(type="text", nullable=true) |
85
|
|
|
*/ |
86
|
|
|
protected $storedIds; |
87
|
|
|
|
88
|
|
|
/** |
89
|
|
|
* @var \DateTime |
90
|
|
|
* |
91
|
|
|
* @ORM\Column(type="datetime") |
92
|
|
|
* @Gedmo\Timestampable(on="create") |
93
|
|
|
*/ |
94
|
|
|
protected $created; |
95
|
|
|
|
96
|
|
|
/** |
97
|
|
|
* @return int |
98
|
|
|
*/ |
99
|
|
|
public function getId() |
100
|
|
|
{ |
101
|
|
|
return $this->id; |
102
|
|
|
} |
103
|
|
|
|
104
|
|
|
/** |
105
|
|
|
* @return Session|null |
106
|
|
|
*/ |
107
|
|
|
public function getSession() |
108
|
|
|
{ |
109
|
|
|
return $this->session; |
110
|
|
|
} |
111
|
|
|
|
112
|
|
|
/** |
113
|
|
|
* @return $this |
114
|
|
|
*/ |
115
|
|
|
public function setSession(?Session $session = null) |
116
|
|
|
{ |
117
|
|
|
$this->session = $session; |
118
|
|
|
|
119
|
|
|
return $this; |
120
|
|
|
} |
121
|
|
|
|
122
|
|
|
/** |
123
|
|
|
* @return string |
124
|
|
|
*/ |
125
|
|
|
public function getFingerprint() |
126
|
|
|
{ |
127
|
|
|
return $this->fingerprint; |
128
|
|
|
} |
129
|
|
|
|
130
|
|
|
/** |
131
|
|
|
* @param string $fingerprint |
132
|
|
|
* |
133
|
|
|
* @return $this |
134
|
|
|
*/ |
135
|
|
|
public function setFingerprint($fingerprint) |
136
|
|
|
{ |
137
|
|
|
$this->fingerprint = $fingerprint; |
138
|
|
|
|
139
|
|
|
return $this; |
140
|
|
|
} |
141
|
|
|
|
142
|
|
|
/** |
143
|
|
|
* @return \DateTime |
144
|
|
|
*/ |
145
|
|
|
public function getCreated() |
146
|
|
|
{ |
147
|
|
|
return $this->created; |
148
|
|
|
} |
149
|
|
|
|
150
|
|
|
/** |
151
|
|
|
* @param \DateTime $created |
152
|
|
|
* |
153
|
|
|
* @return $this |
154
|
|
|
*/ |
155
|
|
|
public function setCreated($created) |
156
|
|
|
{ |
157
|
|
|
$this->created = $created; |
158
|
|
|
|
159
|
|
|
return $this; |
160
|
|
|
} |
161
|
|
|
|
162
|
|
|
/** |
163
|
|
|
* @return string|null |
164
|
|
|
*/ |
165
|
|
|
public function getCanvas() |
166
|
|
|
{ |
167
|
|
|
return $this->canvas; |
168
|
|
|
} |
169
|
|
|
|
170
|
|
|
/** |
171
|
|
|
* @param string $canvas |
172
|
|
|
* |
173
|
|
|
* @return $this |
174
|
|
|
*/ |
175
|
|
|
public function setCanvas($canvas) |
176
|
|
|
{ |
177
|
|
|
$this->canvas = $canvas; |
178
|
|
|
|
179
|
|
|
return $this; |
180
|
|
|
} |
181
|
|
|
|
182
|
|
|
/** |
183
|
|
|
* @return string|null |
184
|
|
|
*/ |
185
|
|
|
public function getFonts() |
186
|
|
|
{ |
187
|
|
|
return $this->fonts; |
188
|
|
|
} |
189
|
|
|
|
190
|
|
|
/** |
191
|
|
|
* @param string $fonts |
192
|
|
|
* |
193
|
|
|
* @return $this |
194
|
|
|
*/ |
195
|
|
|
public function setFonts($fonts) |
196
|
|
|
{ |
197
|
|
|
$this->fonts = $fonts; |
198
|
|
|
|
199
|
|
|
return $this; |
200
|
|
|
} |
201
|
|
|
|
202
|
|
|
/** |
203
|
|
|
* @return string|null |
204
|
|
|
*/ |
205
|
|
|
public function getNavigator() |
206
|
|
|
{ |
207
|
|
|
return $this->navigator; |
208
|
|
|
} |
209
|
|
|
|
210
|
|
|
/** |
211
|
|
|
* @param string $navigator |
212
|
|
|
* |
213
|
|
|
* @return $this |
214
|
|
|
*/ |
215
|
|
|
public function setNavigator($navigator) |
216
|
|
|
{ |
217
|
|
|
$this->navigator = $navigator; |
218
|
|
|
|
219
|
|
|
return $this; |
220
|
|
|
} |
221
|
|
|
|
222
|
|
|
/** |
223
|
|
|
* @return string|null |
224
|
|
|
*/ |
225
|
|
|
public function getPlugins() |
226
|
|
|
{ |
227
|
|
|
return $this->plugins; |
228
|
|
|
} |
229
|
|
|
|
230
|
|
|
/** |
231
|
|
|
* @param string $plugins |
232
|
|
|
* |
233
|
|
|
* @return $this |
234
|
|
|
*/ |
235
|
|
|
public function setPlugins($plugins) |
236
|
|
|
{ |
237
|
|
|
$this->plugins = $plugins; |
238
|
|
|
|
239
|
|
|
return $this; |
240
|
|
|
} |
241
|
|
|
|
242
|
|
|
/** |
243
|
|
|
* @return string|null |
244
|
|
|
*/ |
245
|
|
|
public function getScreen() |
246
|
|
|
{ |
247
|
|
|
return $this->screen; |
248
|
|
|
} |
249
|
|
|
|
250
|
|
|
/** |
251
|
|
|
* @param string $screen |
252
|
|
|
* |
253
|
|
|
* @return $this |
254
|
|
|
*/ |
255
|
|
|
public function setScreen($screen) |
256
|
|
|
{ |
257
|
|
|
$this->screen = $screen; |
258
|
|
|
|
259
|
|
|
return $this; |
260
|
|
|
} |
261
|
|
|
|
262
|
|
|
/** |
263
|
|
|
* @return string|null |
264
|
|
|
*/ |
265
|
|
|
public function getSystemColors() |
266
|
|
|
{ |
267
|
|
|
return $this->systemColors; |
268
|
|
|
} |
269
|
|
|
|
270
|
|
|
/** |
271
|
|
|
* @param string $systemColors |
272
|
|
|
* |
273
|
|
|
* @return $this |
274
|
|
|
*/ |
275
|
|
|
public function setSystemColors($systemColors) |
276
|
|
|
{ |
277
|
|
|
$this->systemColors = $systemColors; |
278
|
|
|
|
279
|
|
|
return $this; |
280
|
|
|
} |
281
|
|
|
|
282
|
|
|
/** |
283
|
|
|
* @return string|null |
284
|
|
|
*/ |
285
|
|
|
public function getStoredIds() |
286
|
|
|
{ |
287
|
|
|
return $this->storedIds; |
288
|
|
|
} |
289
|
|
|
|
290
|
|
|
/** |
291
|
|
|
* @param string $storedIds |
292
|
|
|
* |
293
|
|
|
* @return $this |
294
|
|
|
*/ |
295
|
|
|
public function setStoredIds($storedIds) |
296
|
|
|
{ |
297
|
|
|
$this->storedIds = $storedIds; |
298
|
|
|
|
299
|
|
|
return $this; |
300
|
|
|
} |
301
|
|
|
} |
302
|
|
|
|