grant()
Usage
grant(principal, node, permissions)
Description
Grants the given permissions on the given node to the given principal. This method creates or modifies the security relationship between the first two parameters. Valid values for the permission list are read
, write
, delete
and accessControl
. The permissions are passed in as a comma-separated list (see the examples below). The return value is the empty string. See also revoke()
and is_allowed()
.
Example
${grant(me, node1, 'read')}
${grant(me, node2, 'read, write')}
${grant(me, node3, 'read, write, delete')}
${grant(me, node4, 'read, write, delete, accessControl')}