User extends Handler implements User
Interfaces, Classes and Traits
Table of Contents
- delete() : bool
- Delete user by id.
- error() : array<string|int, mixed>
- Store the error msgs.
- fail() : bool
- check if the error has.
- first() : string
- Get first errror msg .
- get() : array<string|int, mixed>
- Get the error msg.
- getAll() : array<string|int, mixed>
- Get all the users.
- getByWhere() : bool
- Get users using specific field.
- isEmail() : bool
- Check is email is exists or not.
- isLogin() : bool
- Check user is login or not.
- isResetToken() : bool
- Check is reset token is exists or not.
- isToken() : bool
- Check is is verification token is exists or not.
- isUsername() : bool
- Check is username is exists or not.
- last() : string
- Get last error msg.
- loginUser() : mixed
- Get the details of login user.
- logout() : bool
- Logout the user.
- sessionUser() : mixed
- Get the current session user.
- success() : string
- Get the success msg.
Methods
delete()
Delete user by id.
public
delete( $id) : bool
Parameters
Tags
Return values
bool —error()
Store the error msgs.
public
error() : array<string|int, mixed>
Return values
array<string|int, mixed> —fail()
check if the error has.
public
fail() : bool
Return values
bool —first()
Get first errror msg .
public
first([ $key = null ]) : string
Parameters
Return values
string —get()
Get the error msg.
public
get([ $key = null ]) : array<string|int, mixed>
Parameters
Return values
array<string|int, mixed> —getAll()
Get all the users.
public
getAll() : array<string|int, mixed>
Tags
Return values
array<string|int, mixed> —getByWhere()
Get users using specific field.
public
getByWhere((string) $where, (string) $value) : bool
Parameters
- $where : (string)
-
field of user e.g username
- $value : (string)
-
value fo field like , usr01
Tags
Return values
bool —isEmail()
Check is email is exists or not.
public
isEmail((mixed) $email) : bool
Parameters
- $email : (mixed)
-
email of user
Tags
Return values
bool —isLogin()
Check user is login or not.
public
isLogin() : bool
Tags
Return values
bool —isResetToken()
Check is reset token is exists or not.
public
isResetToken((mixed) $token) : bool
Parameters
- $token : (mixed)
-
token of user
Tags
Return values
bool —isToken()
Check is is verification token is exists or not.
public
isToken((mixed) $token) : bool
Parameters
- $token : (mixed)
-
token of user
Tags
Return values
bool —isUsername()
Check is username is exists or not.
public
isUsername((string) $username) : bool
Parameters
- $username : (string)
-
username of user
Tags
Return values
bool —last()
Get last error msg.
public
last([ $key = null ]) : string
Parameters
Return values
string —loginUser()
Get the details of login user.
public
loginUser() : mixed
Tags
Return values
mixed —logout()
Logout the user.
public
logout() : bool
Tags
Return values
bool —sessionUser()
Get the current session user.
public
sessionUser() : mixed
Tags
Return values
mixed —success()
Get the success msg.
public
success() : string