class CACLAccess extends JAccess


Located at : UKNOWVA_ROOT/components/com_community/libraries/core.php

Methods

static boolean
check(integer $userId, string $action, mixed $asset = null)

Method to check if a user is authorised to perform an action, optionally on an asset.

from JAccess
static boolean
checkGroup(integer $groupId, string $action, mixed $asset = null)

Method to check if a group is authorised to perform an action, optionally on an asset.

from JAccess
static JRules
getAssetRules(mixed $asset, boolean $recursive = false)

Method to return the JRules object for an asset. The returned object can optionally hold only the rules explicitly set for the asset or the summation of all inherited rules from parent assets and explicit rules.

from JAccess
static array
getGroupsByUser(integer $userId, boolean $recursive = true)

Method to return a list of user groups mapped to a user. The returned list can optionally hold only the groups explicitly mapped to the user or all groups both explicitly mapped and inherited by the user.

from JAccess
static array
getUsersByGroup(integer $groupId, boolean $recursive = false)

Method to return a list of user Ids contained in a Group

from JAccess
static array
getAuthorisedViewLevels(integer $userId)

Method to return a list of view levels for which the user is authorised.

from JAccess
static array
getActions(string $component, string $section = 'component')

Method to return a list of actions for which permissions can be set given a component and section.

from JAccess
getGroupsByUserId($userId)

No description

getGroupUser($userId)

No description

getGroupID($groupname)

No description

getGroupName($groupId)

No description

is_group_child_of($grp_src, $grp_tgt)

No description

Details

in JAccess at line 51
static boolean check(integer $userId, string $action, mixed $asset = null)

Method to check if a user is authorised to perform an action, optionally on an asset.

Parameters

integer $userId Id of the user for which to check authorisation.
string $action The name of the action to authorise.
mixed $asset Integer asset id or the name of the asset as a string. Defaults to the global asset node.

Return Value

boolean True if authorised.

in JAccess at line 87
static boolean checkGroup(integer $groupId, string $action, mixed $asset = null)

Method to check if a group is authorised to perform an action, optionally on an asset.

Parameters

integer $groupId The path to the group for which to check authorisation.
string $action The name of the action to authorise.
mixed $asset Integer asset id or the name of the asset as a string. Defaults to the global asset node.

Return Value

boolean True if authorised.

in JAccess at line 167
static JRules getAssetRules(mixed $asset, boolean $recursive = false)

Method to return the JRules object for an asset. The returned object can optionally hold only the rules explicitly set for the asset or the summation of all inherited rules from parent assets and explicit rules.

Parameters

mixed $asset Integer asset id or the name of the asset as a string.
boolean $recursive True to return the rules object with inherited rules.

Return Value

JRules JRules object for the asset.

in JAccess at line 224
static array getGroupsByUser(integer $userId, boolean $recursive = true)

Method to return a list of user groups mapped to a user. The returned list can optionally hold only the groups explicitly mapped to the user or all groups both explicitly mapped and inherited by the user.

Parameters

integer $userId Id of the user for which to get the list of groups.
boolean $recursive True to include inherited user groups.

Return Value

array List of user group ids to which the user is mapped.

in JAccess at line 289
static array getUsersByGroup(integer $groupId, boolean $recursive = false)

Method to return a list of user Ids contained in a Group

Parameters

integer $groupId The group Id
boolean $recursive Recursively include all child groups (optional)

Return Value

array

in JAccess at line 323
static array getAuthorisedViewLevels(integer $userId)

Method to return a list of view levels for which the user is authorised.

Parameters

integer $userId Id of the user for which to get the list of authorised view levels.

Return Value

array List of view levels for which the user is authorised.

in JAccess at line 384
static array getActions(string $component, string $section = 'component')

Method to return a list of actions for which permissions can be set given a component and section.

Parameters

string $component The component from which to retrieve the actions.
string $section The name of the section within the component from which to retrieve the actions.

Return Value

array List of actions available for the given component and section.

at line 1388
getGroupsByUserId($userId)

Parameters

$userId

at line 1392
getGroupUser($userId)

Parameters

$userId

at line 1396
getGroupID($groupname)

Parameters

$groupname

at line 1406
getGroupName($groupId)

Parameters

$groupId

at line 1419
is_group_child_of($grp_src, $grp_tgt)

Parameters

$grp_src
$grp_tgt