3 declare(strict_types=1);
19 public function __construct(
int $role_id,
string $type, array $ops,
int $ref_id)
29 return hash(
"sha256", self::class);
34 $ops = implode(
",", $this->ops);
35 return "Set role permission (role id=$this->role_id;type=$this->type;ops=$ops;ref id=$this->ref_id)";
52 $db = $environment->
getResource(Environment::RESOURCE_DATABASE);
54 foreach ($this->ops as $ops_id) {
55 if ($ops_id == self::RBAC_OP_COPY) {
62 'rol_id' => [
'integer', $this->role_id],
63 'type' => [
'text', $this->type],
64 'ops_id' => [
'integer', $ops_id],
65 'parent' => [
'integer', $this->ref_id]
isApplicable(Environment $environment)
getPreconditions(Environment $environment)
__construct(int $role_id, string $type, array $ops, int $ref_id)
achieve(Environment $environment)
getResource(string $id)
Consumers of this method should check if the result is what they expect, e.g.
static _getCustomRBACOperationId(string $operation, \ilDBInterface $ilDB=null)
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
An environment holds resources to be used in the setup process.