Joomla! Platform 12.1

 Class JAccessRule

Description

JAccessRule class.

  • since: 11.4

Located in /libraries/joomla/access/rule.php (line 19)

Class JAccessRule   (Subpackage Access)
Direct descendents
Class Description
ClassJRule Deprecated class placeholder. You should use JAccessRule instead.
Variable Summary
Variable array $data
Method Summary
Constructor JAccessRule __construct (mixed $identities)
Method mixed allow (mixed $identities)
Method array getData ()
Method void mergeIdentities (mixed $identities)
Method void mergeIdentity (integer $identity, boolean $allow)
Method string __toString ()
Variables
array $data = array() (line 27)

A named array

  • since: 11.1
  • access: protected
Methods
Constructor __construct (line 39)

Constructor.

The input array must be in the form: array(-42 => true, 3 => true, 4 => false) or an equivalent JSON encoded string.

  • since: 11.1
  • access: public
JAccessRule __construct (mixed $identities)
  • mixed $identities: A JSON format string (probably from the database) or a named array.

Redefined in descendants as:
allow (line 129)

Checks that this action can be performed by an identity.

The identity is an integer where +ve represents a user group, and -ve represents a user.

  • return: True if allowed, false for an explicit deny, null for an implicit deny.
  • since: 11.1
  • access: public
mixed allow (mixed $identities)
  • mixed $identities: An integer or array of integers representing the identities to check.
getData (line 57)

Get the data for the action.

  • return: A named array
  • since: 11.1
  • access: public
array getData ()
mergeIdentities (line 71)

Merges the identities

  • since: 11.1
  • access: public
void mergeIdentities (mixed $identities)
  • mixed $identities: An integer or array of integers representing the identities to check.
mergeIdentity (line 97)

Merges the values for an identity.

  • since: 11.1
  • access: public
void mergeIdentity (integer $identity, boolean $allow)
  • integer $identity: The identity.
  • boolean $allow: The value for the identity (true == allow, false == deny).
__toString (line 172)

Convert this object into a JSON encoded string.

  • return: JSON encoded string
  • since: 11.1
  • access: public
string __toString ()
/html>