Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
51.64% covered (warning)
51.64%
63 / 122
52.83% covered (warning)
52.83%
28 / 53
CRAP
0.00% covered (danger)
0.00%
0 / 1
Identification
51.64% covered (warning)
51.64%
63 / 122
52.83% covered (warning)
52.83%
28 / 53
943.08
0.00% covered (danger)
0.00%
0 / 1
 __construct
100.00% covered (success)
100.00%
19 / 19
100.00% covered (success)
100.00%
1 / 1
20
 __toString
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 swaggerTypes
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 swaggerFormats
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 attributeMap
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setters
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 getters
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 getModelName
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 listInvalidProperties
0.00% covered (danger)
0.00%
0 / 28
0.00% covered (danger)
0.00%
0 / 1
210
 valid
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 getVisitorId
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setVisitorId
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getRequestId
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setRequestId
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getBrowserDetails
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setBrowserDetails
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getIncognito
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 setIncognito
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getIp
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 setIp
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getIpLocation
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setIpLocation
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getLinkedId
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 setLinkedId
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getSuspect
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 setSuspect
0.00% covered (danger)
0.00%
0 / 2
0.00% covered (danger)
0.00%
0 / 1
2
 getTimestamp
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 setTimestamp
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getTime
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setTime
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getUrl
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 setUrl
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getTag
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 setTag
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getConfidence
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setConfidence
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getVisitorFound
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 setVisitorFound
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getFirstSeenAt
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 setFirstSeenAt
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getLastSeenAt
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setLastSeenAt
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getComponents
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 setComponents
0.00% covered (danger)
0.00%
0 / 2
0.00% covered (danger)
0.00%
0 / 1
2
 getReplayed
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 setReplayed
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getSdk
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 setSdk
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 offsetExists
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 offsetGet
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
6
 offsetSet
0.00% covered (danger)
0.00%
0 / 3
0.00% covered (danger)
0.00%
0 / 1
6
 offsetUnset
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 toPrettyString
0.00% covered (danger)
0.00%
0 / 4
0.00% covered (danger)
0.00%
0 / 1
2
1<?php
2/**
3 * Identification.
4 *
5 * @category Class
6 *
7 * @author   Swagger Codegen team
8 *
9 * @see     https://github.com/swagger-api/swagger-codegen
10 */
11
12/**
13 * Fingerprint Server API.
14 *
15 * Fingerprint Server API allows you to search, update, and delete identification events in a server environment. It can be used for data exports, decision-making, and data analysis scenarios. Server API is intended for server-side usage, it's not intended to be used from the client side, whether it's a browser or a mobile device.
16 *
17 * OpenAPI spec version: 3
18 * Contact: support@fingerprint.com
19 * Generated by: https://github.com/swagger-api/swagger-codegen.git
20 * Swagger Codegen version: 3.0.34
21 */
22/**
23 * NOTE: This class is auto generated by the swagger code generator program.
24 * https://github.com/swagger-api/swagger-codegen
25 * Do not edit the class manually.
26 */
27
28namespace Fingerprint\ServerAPI\Model;
29
30use Fingerprint\ServerAPI\ObjectSerializer;
31
32/**
33 * Identification Class Doc Comment.
34 *
35 * @category Class
36 *
37 * @author   Swagger Codegen team
38 *
39 * @see     https://github.com/swagger-api/swagger-codegen
40 */
41class Identification implements ModelInterface, \ArrayAccess
42{
43    /**
44     * The original name of the model.
45     *
46     */
47    protected static string $swaggerModelName = 'Identification';
48
49    /**
50     * Array of property to type mappings. Used for (de)serialization.
51     *
52     * @var string[]
53     */
54    protected static array $swaggerTypes = [
55        'visitor_id' => 'string',
56        'request_id' => 'string',
57        'browser_details' => '\Fingerprint\ServerAPI\Model\BrowserDetails',
58        'incognito' => 'bool',
59        'ip' => 'string',
60        'ip_location' => '\Fingerprint\ServerAPI\Model\DeprecatedGeolocation',
61        'linked_id' => 'string',
62        'suspect' => 'bool',
63        'timestamp' => 'int',
64        'time' => '\DateTime',
65        'url' => 'string',
66        'tag' => 'array',
67        'confidence' => '\Fingerprint\ServerAPI\Model\IdentificationConfidence',
68        'visitor_found' => 'bool',
69        'first_seen_at' => '\Fingerprint\ServerAPI\Model\IdentificationSeenAt',
70        'last_seen_at' => '\Fingerprint\ServerAPI\Model\IdentificationSeenAt',
71        'components' => 'array',
72        'replayed' => 'bool',
73        'sdk' => '\Fingerprint\ServerAPI\Model\SDK'];
74
75    /**
76     * Array of property to format mappings. Used for (de)serialization.
77     *
78     * @var string[]
79     */
80    protected static array $swaggerFormats = [
81        'visitor_id' => null,
82        'request_id' => null,
83        'browser_details' => null,
84        'incognito' => null,
85        'ip' => null,
86        'ip_location' => null,
87        'linked_id' => null,
88        'suspect' => null,
89        'timestamp' => 'int64',
90        'time' => 'date-time',
91        'url' => null,
92        'tag' => null,
93        'confidence' => null,
94        'visitor_found' => null,
95        'first_seen_at' => null,
96        'last_seen_at' => null,
97        'components' => null,
98        'replayed' => null,
99        'sdk' => null];
100
101    /**
102     * Array of attributes where the key is the local name,
103     * and the value is the original name.
104     *
105     * @var string[]
106     */
107    protected static array $attributeMap = [
108        'visitor_id' => 'visitorId',
109        'request_id' => 'requestId',
110        'browser_details' => 'browserDetails',
111        'incognito' => 'incognito',
112        'ip' => 'ip',
113        'ip_location' => 'ipLocation',
114        'linked_id' => 'linkedId',
115        'suspect' => 'suspect',
116        'timestamp' => 'timestamp',
117        'time' => 'time',
118        'url' => 'url',
119        'tag' => 'tag',
120        'confidence' => 'confidence',
121        'visitor_found' => 'visitorFound',
122        'first_seen_at' => 'firstSeenAt',
123        'last_seen_at' => 'lastSeenAt',
124        'components' => 'components',
125        'replayed' => 'replayed',
126        'sdk' => 'sdk'];
127
128    /**
129     * Array of attributes to setter functions (for deserialization of responses).
130     *
131     * @var string[]
132     */
133    protected static array $setters = [
134        'visitor_id' => 'setVisitorId',
135        'request_id' => 'setRequestId',
136        'browser_details' => 'setBrowserDetails',
137        'incognito' => 'setIncognito',
138        'ip' => 'setIp',
139        'ip_location' => 'setIpLocation',
140        'linked_id' => 'setLinkedId',
141        'suspect' => 'setSuspect',
142        'timestamp' => 'setTimestamp',
143        'time' => 'setTime',
144        'url' => 'setUrl',
145        'tag' => 'setTag',
146        'confidence' => 'setConfidence',
147        'visitor_found' => 'setVisitorFound',
148        'first_seen_at' => 'setFirstSeenAt',
149        'last_seen_at' => 'setLastSeenAt',
150        'components' => 'setComponents',
151        'replayed' => 'setReplayed',
152        'sdk' => 'setSdk'];
153
154    /**
155     * Array of attributes to getter functions (for serialization of requests).
156     *
157     * @var string[]
158     */
159    protected static array $getters = [
160        'visitor_id' => 'getVisitorId',
161        'request_id' => 'getRequestId',
162        'browser_details' => 'getBrowserDetails',
163        'incognito' => 'getIncognito',
164        'ip' => 'getIp',
165        'ip_location' => 'getIpLocation',
166        'linked_id' => 'getLinkedId',
167        'suspect' => 'getSuspect',
168        'timestamp' => 'getTimestamp',
169        'time' => 'getTime',
170        'url' => 'getUrl',
171        'tag' => 'getTag',
172        'confidence' => 'getConfidence',
173        'visitor_found' => 'getVisitorFound',
174        'first_seen_at' => 'getFirstSeenAt',
175        'last_seen_at' => 'getLastSeenAt',
176        'components' => 'getComponents',
177        'replayed' => 'getReplayed',
178        'sdk' => 'getSdk'];
179
180    /**
181     * Associative array for storing property values.
182     *
183     * @var mixed[]
184     */
185    protected array $container = [];
186
187    /**
188     * Constructor.
189     *
190     * @param mixed[] $data Associated array of property values
191     *                      initializing the model
192     */
193    public function __construct(?array $data = null)
194    {
195        $this->container['visitor_id'] = isset($data['visitor_id']) ? $data['visitor_id'] : null;
196        $this->container['request_id'] = isset($data['request_id']) ? $data['request_id'] : null;
197        $this->container['browser_details'] = isset($data['browser_details']) ? $data['browser_details'] : null;
198        $this->container['incognito'] = isset($data['incognito']) ? $data['incognito'] : null;
199        $this->container['ip'] = isset($data['ip']) ? $data['ip'] : null;
200        $this->container['ip_location'] = isset($data['ip_location']) ? $data['ip_location'] : null;
201        $this->container['linked_id'] = isset($data['linked_id']) ? $data['linked_id'] : null;
202        $this->container['suspect'] = isset($data['suspect']) ? $data['suspect'] : null;
203        $this->container['timestamp'] = isset($data['timestamp']) ? $data['timestamp'] : null;
204        $this->container['time'] = isset($data['time']) ? $data['time'] : null;
205        $this->container['url'] = isset($data['url']) ? $data['url'] : null;
206        $this->container['tag'] = isset($data['tag']) ? $data['tag'] : null;
207        $this->container['confidence'] = isset($data['confidence']) ? $data['confidence'] : null;
208        $this->container['visitor_found'] = isset($data['visitor_found']) ? $data['visitor_found'] : null;
209        $this->container['first_seen_at'] = isset($data['first_seen_at']) ? $data['first_seen_at'] : null;
210        $this->container['last_seen_at'] = isset($data['last_seen_at']) ? $data['last_seen_at'] : null;
211        $this->container['components'] = isset($data['components']) ? $data['components'] : null;
212        $this->container['replayed'] = isset($data['replayed']) ? $data['replayed'] : null;
213        $this->container['sdk'] = isset($data['sdk']) ? $data['sdk'] : null;
214    }
215
216    /**
217     * Gets the string presentation of the object.
218     *
219     */
220    public function __toString(): string
221    {
222        return json_encode(ObjectSerializer::sanitizeForSerialization($this));
223    }
224
225    /**
226     * Array of property to type mappings. Used for (de)serialization.
227     */
228    public static function swaggerTypes(): array
229    {
230        return self::$swaggerTypes;
231    }
232
233    /**
234     * Array of property to format mappings. Used for (de)serialization.
235     */
236    public static function swaggerFormats(): array
237    {
238        return self::$swaggerFormats;
239    }
240
241    /**
242     * Array of attributes where the key is the local name,
243     * and the value is the original name.
244     */
245    public static function attributeMap(): array
246    {
247        return self::$attributeMap;
248    }
249
250    /**
251     * Array of attributes to setter functions (for deserialization of responses).
252     */
253    public static function setters(): array
254    {
255        return self::$setters;
256    }
257
258    /**
259     * Array of attributes to getter functions (for serialization of requests).
260     */
261    public static function getters(): array
262    {
263        return self::$getters;
264    }
265
266    /**
267     * The original name of the model.
268     */
269    public function getModelName(): string
270    {
271        return self::$swaggerModelName;
272    }
273
274    /**
275     * Show all the invalid properties with reasons.
276     *
277     * @return array invalid properties with reasons
278     */
279    public function listInvalidProperties(): array
280    {
281        $invalidProperties = [];
282
283        if (null === $this->container['visitor_id']) {
284            $invalidProperties[] = "'visitor_id' can't be null";
285        }
286        if (null === $this->container['request_id']) {
287            $invalidProperties[] = "'request_id' can't be null";
288        }
289        if (null === $this->container['browser_details']) {
290            $invalidProperties[] = "'browser_details' can't be null";
291        }
292        if (null === $this->container['incognito']) {
293            $invalidProperties[] = "'incognito' can't be null";
294        }
295        if (null === $this->container['ip']) {
296            $invalidProperties[] = "'ip' can't be null";
297        }
298        if (null === $this->container['timestamp']) {
299            $invalidProperties[] = "'timestamp' can't be null";
300        }
301        if (null === $this->container['time']) {
302            $invalidProperties[] = "'time' can't be null";
303        }
304        if (null === $this->container['url']) {
305            $invalidProperties[] = "'url' can't be null";
306        }
307        if (null === $this->container['tag']) {
308            $invalidProperties[] = "'tag' can't be null";
309        }
310        if (null === $this->container['visitor_found']) {
311            $invalidProperties[] = "'visitor_found' can't be null";
312        }
313        if (null === $this->container['first_seen_at']) {
314            $invalidProperties[] = "'first_seen_at' can't be null";
315        }
316        if (null === $this->container['last_seen_at']) {
317            $invalidProperties[] = "'last_seen_at' can't be null";
318        }
319        if (null === $this->container['replayed']) {
320            $invalidProperties[] = "'replayed' can't be null";
321        }
322
323        return $invalidProperties;
324    }
325
326    /**
327     * Validate all the properties in the model
328     * return true if all passed.
329     *
330     * @return bool True if all properties are valid
331     */
332    public function valid(): bool
333    {
334        return 0 === count($this->listInvalidProperties());
335    }
336
337    /**
338     * Gets visitor_id.
339     */
340    public function getVisitorId(): string
341    {
342        return $this->container['visitor_id'];
343    }
344
345    /**
346     * Sets visitor_id.
347     *
348     * @param string $visitor_id string of 20 characters that uniquely identifies the visitor's browser
349     *
350     * @return $this
351     */
352    public function setVisitorId(string $visitor_id): self
353    {
354        $this->container['visitor_id'] = $visitor_id;
355
356        return $this;
357    }
358
359    /**
360     * Gets request_id.
361     */
362    public function getRequestId(): string
363    {
364        return $this->container['request_id'];
365    }
366
367    /**
368     * Sets request_id.
369     *
370     * @param string $request_id unique identifier of the user's request
371     *
372     * @return $this
373     */
374    public function setRequestId(string $request_id): self
375    {
376        $this->container['request_id'] = $request_id;
377
378        return $this;
379    }
380
381    /**
382     * Gets browser_details.
383     */
384    public function getBrowserDetails(): BrowserDetails
385    {
386        return $this->container['browser_details'];
387    }
388
389    /**
390     * Sets browser_details.
391     *
392     * @param BrowserDetails $browser_details browser_details
393     *
394     * @return $this
395     */
396    public function setBrowserDetails(BrowserDetails $browser_details): self
397    {
398        $this->container['browser_details'] = $browser_details;
399
400        return $this;
401    }
402
403    /**
404     * Gets incognito.
405     */
406    public function getIncognito(): bool
407    {
408        return $this->container['incognito'];
409    }
410
411    /**
412     * Sets incognito.
413     *
414     * @param bool $incognito flag if user used incognito session
415     *
416     * @return $this
417     */
418    public function setIncognito(bool $incognito): self
419    {
420        $this->container['incognito'] = $incognito;
421
422        return $this;
423    }
424
425    /**
426     * Gets ip.
427     */
428    public function getIp(): string
429    {
430        return $this->container['ip'];
431    }
432
433    /**
434     * Sets ip.
435     *
436     * @param string $ip IP address of the requesting browser or bot
437     *
438     * @return $this
439     */
440    public function setIp(string $ip): self
441    {
442        $this->container['ip'] = $ip;
443
444        return $this;
445    }
446
447    /**
448     * Gets ip_location.
449     */
450    public function getIpLocation(): ?DeprecatedGeolocation
451    {
452        return $this->container['ip_location'];
453    }
454
455    /**
456     * Sets ip_location.
457     *
458     * @param ?\Fingerprint\ServerAPI\Model\DeprecatedGeolocation $ip_location ip_location
459     *
460     * @return $this
461     */
462    public function setIpLocation(?DeprecatedGeolocation $ip_location): self
463    {
464        $this->container['ip_location'] = $ip_location;
465
466        return $this;
467    }
468
469    /**
470     * Gets linked_id.
471     */
472    public function getLinkedId(): ?string
473    {
474        return $this->container['linked_id'];
475    }
476
477    /**
478     * Sets linked_id.
479     *
480     * @param ?string $linked_id a customer-provided id that was sent with the request
481     *
482     * @return $this
483     */
484    public function setLinkedId(?string $linked_id): self
485    {
486        $this->container['linked_id'] = $linked_id;
487
488        return $this;
489    }
490
491    /**
492     * Gets suspect.
493     */
494    public function getSuspect(): ?bool
495    {
496        return $this->container['suspect'];
497    }
498
499    /**
500     * Sets suspect.
501     *
502     * @param ?bool $suspect Field is `true` if you have previously set the `suspect` flag for this event using the [Server API Update event endpoint](https://dev.fingerprint.com/reference/updateevent).
503     *
504     * @return $this
505     */
506    public function setSuspect(?bool $suspect): self
507    {
508        $this->container['suspect'] = $suspect;
509
510        return $this;
511    }
512
513    /**
514     * Gets timestamp.
515     */
516    public function getTimestamp(): int
517    {
518        return $this->container['timestamp'];
519    }
520
521    /**
522     * Sets timestamp.
523     *
524     * @param int $timestamp timestamp of the event with millisecond precision in Unix time
525     *
526     * @return $this
527     */
528    public function setTimestamp(int $timestamp): self
529    {
530        $this->container['timestamp'] = $timestamp;
531
532        return $this;
533    }
534
535    /**
536     * Gets time.
537     */
538    public function getTime(): \DateTime
539    {
540        return $this->container['time'];
541    }
542
543    /**
544     * Sets time.
545     *
546     * @param \DateTime $time Time expressed according to ISO 8601 in UTC format, when the request from the JS agent was made. We recommend to treat requests that are older than 2 minutes as malicious. Otherwise, request replay attacks are possible.
547     *
548     * @return $this
549     */
550    public function setTime(\DateTime $time): self
551    {
552        $this->container['time'] = $time;
553
554        return $this;
555    }
556
557    /**
558     * Gets url.
559     */
560    public function getUrl(): string
561    {
562        return $this->container['url'];
563    }
564
565    /**
566     * Sets url.
567     *
568     * @param string $url page URL from which the request was sent
569     *
570     * @return $this
571     */
572    public function setUrl(string $url): self
573    {
574        $this->container['url'] = $url;
575
576        return $this;
577    }
578
579    /**
580     * Gets tag.
581     */
582    public function getTag(): array
583    {
584        return $this->container['tag'];
585    }
586
587    /**
588     * Sets tag.
589     *
590     * @param array $tag tag
591     *
592     * @return $this
593     */
594    public function setTag(array $tag): self
595    {
596        $this->container['tag'] = $tag;
597
598        return $this;
599    }
600
601    /**
602     * Gets confidence.
603     */
604    public function getConfidence(): ?IdentificationConfidence
605    {
606        return $this->container['confidence'];
607    }
608
609    /**
610     * Sets confidence.
611     *
612     * @param ?\Fingerprint\ServerAPI\Model\IdentificationConfidence $confidence confidence
613     *
614     * @return $this
615     */
616    public function setConfidence(?IdentificationConfidence $confidence): self
617    {
618        $this->container['confidence'] = $confidence;
619
620        return $this;
621    }
622
623    /**
624     * Gets visitor_found.
625     */
626    public function getVisitorFound(): bool
627    {
628        return $this->container['visitor_found'];
629    }
630
631    /**
632     * Sets visitor_found.
633     *
634     * @param bool $visitor_found attribute represents if a visitor had been identified before
635     *
636     * @return $this
637     */
638    public function setVisitorFound(bool $visitor_found): self
639    {
640        $this->container['visitor_found'] = $visitor_found;
641
642        return $this;
643    }
644
645    /**
646     * Gets first_seen_at.
647     */
648    public function getFirstSeenAt(): IdentificationSeenAt
649    {
650        return $this->container['first_seen_at'];
651    }
652
653    /**
654     * Sets first_seen_at.
655     *
656     * @param IdentificationSeenAt $first_seen_at first_seen_at
657     *
658     * @return $this
659     */
660    public function setFirstSeenAt(IdentificationSeenAt $first_seen_at): self
661    {
662        $this->container['first_seen_at'] = $first_seen_at;
663
664        return $this;
665    }
666
667    /**
668     * Gets last_seen_at.
669     */
670    public function getLastSeenAt(): IdentificationSeenAt
671    {
672        return $this->container['last_seen_at'];
673    }
674
675    /**
676     * Sets last_seen_at.
677     *
678     * @param IdentificationSeenAt $last_seen_at last_seen_at
679     *
680     * @return $this
681     */
682    public function setLastSeenAt(IdentificationSeenAt $last_seen_at): self
683    {
684        $this->container['last_seen_at'] = $last_seen_at;
685
686        return $this;
687    }
688
689    /**
690     * Gets components.
691     */
692    public function getComponents(): ?array
693    {
694        return $this->container['components'];
695    }
696
697    /**
698     * Sets components.
699     *
700     * @param ?array $components components
701     *
702     * @return $this
703     */
704    public function setComponents(?array $components): self
705    {
706        $this->container['components'] = $components;
707
708        return $this;
709    }
710
711    /**
712     * Gets replayed.
713     */
714    public function getReplayed(): bool
715    {
716        return $this->container['replayed'];
717    }
718
719    /**
720     * Sets replayed.
721     *
722     * @param bool $replayed `true` if we determined that this payload was replayed, `false` otherwise
723     *
724     * @return $this
725     */
726    public function setReplayed(bool $replayed): self
727    {
728        $this->container['replayed'] = $replayed;
729
730        return $this;
731    }
732
733    /**
734     * Gets sdk.
735     */
736    public function getSdk(): ?SDK
737    {
738        return $this->container['sdk'];
739    }
740
741    /**
742     * Sets sdk.
743     *
744     * @param ?\Fingerprint\ServerAPI\Model\SDK $sdk sdk
745     *
746     * @return $this
747     */
748    public function setSdk(?SDK $sdk): self
749    {
750        $this->container['sdk'] = $sdk;
751
752        return $this;
753    }
754
755    /**
756     * Returns true if offset exists. False otherwise.
757     *
758     * @param int $offset Offset
759     */
760    public function offsetExists($offset): bool
761    {
762        return isset($this->container[$offset]);
763    }
764
765    /**
766     * Gets offset.
767     *
768     * @param int $offset Offset
769     */
770    public function offsetGet($offset): mixed
771    {
772        return isset($this->container[$offset]) ? $this->container[$offset] : null;
773    }
774
775    /**
776     * Sets value based on offset.
777     *
778     * @param int   $offset Offset
779     * @param mixed $value  Value to be set
780     */
781    public function offsetSet($offset, mixed $value): void
782    {
783        if (is_null($offset)) {
784            $this->container[] = $value;
785        } else {
786            $this->container[$offset] = $value;
787        }
788    }
789
790    /**
791     * Unsets offset.
792     *
793     * @param int $offset Offset
794     */
795    public function offsetUnset($offset): void
796    {
797        unset($this->container[$offset]);
798    }
799
800    /**
801     * Gets the string presentation of the object in a pretty JSON format.
802     *
803     */
804    public function toPrettyString(): string
805    {
806        return json_encode(
807            ObjectSerializer::sanitizeForSerialization($this),
808            JSON_PRETTY_PRINT
809        );
810    }
811}