Class User
This model describes the user data
- Hawk\Model uses Hawk\Utils
-
Hawk\User
Methods summary
public
|
|
public static
array
|
|
public static
|
|
public static
|
|
public
mixed
|
|
public
|
#
setProfileData( string $prop, string $value )
Set the user's profile data. This method does not register the data in database, only set in the user properties |
public
|
|
public
mixed
|
#
getOptions( string $name = '' )
Get the user options. This function returns the option value for $name. If $name is not set, it returns the array containing all the user options |
public
|
|
public
boolean
|
|
public
string
|
|
public
string
|
#
getDisplayName( )
Get the user's full name. This method returns the real name if it set in the user's profile, else, it returns his username |
public
boolean
|
|
public
boolean
|
|
public
boolean
|
#
isRemovable( )
Check of the user is removable. A user is removable if he's not the one executing the current script, and if he's not a guest or the main application administrator |
Methods inherited from Hawk\Model
add(),
addIfNotExists(),
countElementsByExample(),
countElementsBySQL(),
delete(),
deleteByExample(),
deleteBySQL(),
getByExample(),
getById(),
getBySQL(),
getData(),
getDbInstance(),
getDbName(),
getListByExample(),
getListBySQL(),
getPrimaryColumn(),
getTable(),
save(),
set(),
setDbName(),
setPrimaryColumn(),
setTable(),
update()
Methods used from Hawk\Utils
Constants summary
integer |
GUEST_USER_ID
The id of guest users |
#
0
|
integer |
ROOT_USER_ID
The id for the first administrator user |
#
1
|
Properties summary
protected static
string
|
$tablename
The associated table |
#
"User"
|