Jelix 1.8.14-pre

jAcl
in package

Main class to query the acl system, and to know value of a right.

you should call this class (all method are static) when you want to know if the current user have a right

Tags
subpackage

jacl

static

Table of Contents

check()  : bool
call this method to know if the current user has the right with the given value.
clearCache()  : mixed
clear right cache.
getRight()  : array<string|int, mixed>
return the value of the right on the given subject (and on the optional resource).
_getDriver()  : jIAclDriver
load the acl driver.

Methods

check()

call this method to know if the current user has the right with the given value.

public static check(string $subject[, string $value = true ][, string $resource = null ]) : bool
Parameters
$subject : string

the key of the subject to check

$value : string = true

the value to test against

$resource : string = null

the id of a resource

Tags
Return values
bool

true if yes

clearCache()

clear right cache.

public static clearCache() : mixed
Tags
since
1.0b2
Return values
mixed

getRight()

return the value of the right on the given subject (and on the optional resource).

public static getRight(string $subject[, string $resource = null ]) : array<string|int, mixed>
Parameters
$subject : string

the key of the subject

$resource : string = null

the id of a resource

Tags
Return values
array<string|int, mixed>

list of values corresponding to the right

Search results