1
|
|
|
<?php |
2
|
|
|
|
3
|
|
|
declare(strict_types=1); |
4
|
|
|
|
5
|
|
|
namespace Pnz\MattermostClient\Model\User; |
6
|
|
|
|
7
|
|
|
use Pnz\MattermostClient\Model\Model; |
8
|
|
|
|
9
|
|
|
final class User extends Model |
10
|
|
|
{ |
11
|
3 |
|
public function getId(): ?string |
12
|
|
|
{ |
13
|
3 |
|
return $this->data['id']; |
14
|
|
|
} |
15
|
|
|
|
16
|
3 |
|
public function getCreateAt(): ?int |
17
|
|
|
{ |
18
|
3 |
|
return $this->data['create_at']; |
19
|
|
|
} |
20
|
|
|
|
21
|
2 |
|
public function getDeleteAt(): ?int |
22
|
|
|
{ |
23
|
2 |
|
return $this->data['delete_at']; |
24
|
|
|
} |
25
|
|
|
|
26
|
3 |
|
public function getUpdateAt(): ?int |
27
|
|
|
{ |
28
|
3 |
|
return $this->data['update_at']; |
29
|
|
|
} |
30
|
|
|
|
31
|
3 |
|
public function getRoles(): ?string |
32
|
|
|
{ |
33
|
3 |
|
return $this->data['roles']; |
34
|
|
|
} |
35
|
|
|
|
36
|
3 |
|
public function getAllowMarketing(): ?bool |
37
|
|
|
{ |
38
|
3 |
|
return $this->data['allow_marketing']; |
39
|
|
|
} |
40
|
|
|
|
41
|
3 |
|
public function getLocale(): ?string |
42
|
|
|
{ |
43
|
3 |
|
return $this->data['locale']; |
44
|
|
|
} |
45
|
|
|
|
46
|
3 |
|
public function getUsername(): ?string |
47
|
|
|
{ |
48
|
3 |
|
return $this->data['username']; |
49
|
|
|
} |
50
|
|
|
|
51
|
3 |
|
public function getAuthData(): ?string |
52
|
|
|
{ |
53
|
3 |
|
return $this->data['auth_data']; |
54
|
|
|
} |
55
|
|
|
|
56
|
3 |
|
public function getEmail(): ?string |
57
|
|
|
{ |
58
|
3 |
|
return $this->data['email']; |
59
|
|
|
} |
60
|
|
|
|
61
|
3 |
|
public function getFirstName(): ?string |
62
|
|
|
{ |
63
|
3 |
|
return $this->data['first_name']; |
64
|
|
|
} |
65
|
|
|
|
66
|
3 |
|
public function getLastName(): ?string |
67
|
|
|
{ |
68
|
3 |
|
return $this->data['last_name']; |
69
|
|
|
} |
70
|
|
|
|
71
|
3 |
|
public function getNickname(): ?string |
72
|
|
|
{ |
73
|
3 |
|
return $this->data['nickname']; |
74
|
|
|
} |
75
|
|
|
|
76
|
3 |
|
public function getEmailVerified(): ?bool |
77
|
|
|
{ |
78
|
3 |
|
return $this->data['email_verified']; |
79
|
|
|
} |
80
|
|
|
|
81
|
3 |
|
protected static function getFields(): array |
82
|
|
|
{ |
83
|
|
|
return [ |
84
|
3 |
|
'id', |
85
|
|
|
'create_at', |
86
|
|
|
'update_at', |
87
|
|
|
'delete_at', |
88
|
|
|
'roles', |
89
|
|
|
'allow_marketing', |
90
|
|
|
'locale', |
91
|
|
|
'username', |
92
|
|
|
'auth_data', |
93
|
|
|
'email', |
94
|
|
|
'email_verified', |
95
|
|
|
'notify_props', |
96
|
|
|
'last_password_update', |
97
|
|
|
'last_name', |
98
|
|
|
'nickname', |
99
|
|
|
'first_name', |
100
|
|
|
]; |
101
|
|
|
} |
102
|
|
|
} |
103
|
|
|
|