SimpleIdentity
class SimpleIdentity implements IIdentity
Default implementation of IIdentity.
Properties
| string|int | $id | ||
| list<string> | $roles | ||
| array<string,mixed> | $data |
Methods
__construct(string|int $id, string|array|null $roles = null, iterable|null $data = null)
No description
setId(string|int $id)
Sets the ID of user.
string|int
getId()
Returns the ID of user.
setRoles(array $roles)
Sets a list of roles that the user is a member of.
array
getRoles()
Returns a list of roles that the user is a member of.
array
getData()
Returns user data.
void
__set(string $key, mixed $value)
Sets user data value.
mixed
__get(string $key)
Returns user data value.
bool
__isset(string $key)
No description
array
__serialize()
No description
void
__unserialize(array $data)
No description
Details
at line 34
__construct(string|int $id, string|array|null $roles = null, iterable|null $data = null)
No description
at line 45
SimpleIdentity
setId(string|int $id)
Sets the ID of user.
at line 55
string|int
getId()
Returns the ID of user.
at line 65
SimpleIdentity
setRoles(array $roles)
Sets a list of roles that the user is a member of.
at line 76
array
getRoles()
Returns a list of roles that the user is a member of.
at line 86
array
getData()
Returns user data.
at line 95
void
__set(string $key, mixed $value)
Sets user data value.
at line 109
mixed
__get(string $key)
Returns user data value.
at line 121
bool
__isset(string $key)
No description
at line 127
array
__serialize()
No description
at line 137
void
__unserialize(array $data)
No description