rex_user_role_interface
in
Interface for user roles.
Tags
Table of Contents
Methods
- get() : static|null
- Returns the role for the given ID.
- getComplexPerm() : rex_complex_perm|null
- Returns the complex perm.
- hasPerm() : bool
- Returns if the role has the given permission.
Methods
get()
Returns the role for the given ID.
public
static get(string $id) : static|null
Parameters
- $id : string
-
IDs comma seperated
Return values
static|null —Role instance
getComplexPerm()
Returns the complex perm.
public
getComplexPerm(rex_user $user, string $key) : rex_complex_perm|null
Parameters
- $user : rex_user
-
User instance
- $key : string
-
Complex perm key
Return values
rex_complex_perm|null —Complex perm
hasPerm()
Returns if the role has the given permission.
public
hasPerm(string $perm) : bool
Parameters
- $perm : string
-
Perm key