expPermissions

define

"BASE" "../../.."

package

Subsystems

Methods

exdoc Looks to the permission data and checks to see if the current user has been granted the given permission(s) on the granted the given location.

check(string $permission, object $location) : boolean
static

Returns true if the permission is granted, false if it is not.

node

Subsystems:expPermissions

Arguments

$permission

string

The name of the permission to check

$location

object

The location to check on. This will be passed to getLocationHierarchy (defined by the module) for a full hierarchy of permissions.

Response

boolean

exdoc Checks to see if the given group has been given a specific permission on a location.

checkGroup(\group/object $group, string $permission, object $location, boolean $explicitOnly = false) : boolean
static

Returns true if the permission is granted, false if it is not.

node

Subsystems:expPermissions

Arguments

$group

\group/object

The group to check

$permission

string

The name of the permission to check

$location

object

The location to check on.

$explicitOnly

boolean

Response

boolean

exdoc Checks to see if the given user has been given a specific permission.

checkUser(\user/object $user, string $permission, object $location, boolean $explicitOnly = false) : boolean
static

Handles explicit checks (actually assigned to the user) implicit and inherited checks (assigned to a group the user belongs to). Returns true if the permission is granted, false if it is not.

node

Subsystems:expPermissions

Arguments

$user

\user/object

The user to check permission on

$permission

string

The name of the permission to check

$location

object

The location to check on.

$explicitOnly

boolean

Whether to check for explicit/implicit assignment or inherited.

Response

boolean

exdoc Grants the specified permission to the specified user, on the given location

grant(\user/object $user, string $permission, object $location) 
static
node

Subsystems:expPermissions

Arguments

$user

\user/object

The user to grant the permission to

$permission

string

The name of the permission to grant

$location

object

The location to grant the permission on

exdoc Grants the specified permission to the specified user group, on the given location

grantGroup(\group/object $group, string $permission, object $location) 
static
node

Subsystems:expPermissions

Arguments

$group

\group/object

The group to grant the permission to

$permission

string

The name of the permission to grant

$location

object

The location to grant the permission on

exdoc Loads permission data from the database for the specified user.

load(\user/object $user) 
static
node

Subsystems:expPermissions

Arguments

$user

\user/object

the user to load permissions for.

exdoc Removes all permissions from a user, on a specific location.

revokeAll(\user/object $user, object $location) : mixed
static
node

Subsystems:expPermissions

Arguments

$user

\user/object

The user to remove all permissions from

$location

object

The location to remove all permission on

Response

mixed

exdoc Removes all permissions from a group, on a specific location.

revokeAllGroup(\group/object $group, object $location) : mixed
static
node

Subsystems:expPermissions

Arguments

$group

\group/object

The group to remove all permissions from

$location

object

The location to remove all permission on

Response

mixed

exdoc Removes all user and group permissions, on a specific location.

revokeComplete(object $location) : boolean
static
node

Subsystems:expPermissions

Arguments

$location

object

Response

boolean

exdoc This call will force all active session to reload their permission data. This is useful if permissions are assigned or revoked, and is required to see these changes.

triggerRefresh() 
static
node

Subsystems:expPermissions

deprecated 2.3.3

moved into expSession