19 declare(strict_types=1);
57 $this->rbacadmin = $DIC->rbac()->admin();
58 $this->rbacreview = $DIC->rbac()->review();
59 $this->rbacsystem = $DIC->rbac()->system();
60 $this->parent_cnt = 0;
82 if ($type ===
"end") {
88 if (is_array($attr)) {
89 foreach ($attr as $k => $v) {
90 $tag .=
" " . $k .
"=\"$v\"";
105 public function handlerBeginTag($a_xml_parser,
string $a_name, array $a_attribs): void
110 $cur_parent = $this->parent[$this->parent_cnt - 1];
112 $this->category->setImportId($a_attribs[
"Id"] .
" (#" . $cur_parent .
")");
113 $this->default_language = $a_attribs[
"DefaultLanguage"];
114 $this->category->setTitle($a_attribs[
"Id"]);
115 $this->category->create();
116 $this->category->createReference();
117 $this->category->putInTree($cur_parent);
118 $this->parent[$this->parent_cnt++] = $this->category->getRefId();
122 $this->cur_spec_lang = $a_attribs[
"Language"];
137 unset($this->category, $this->parent[$this->parent_cnt - 1]);
143 if ($this->cur_spec_lang === $this->default_language) {
144 $this->category->setTitle($this->cur_title);
145 $this->category->setDescription($this->cur_description);
146 $this->category->update();
149 $this->category->addTranslation(
151 $this->cur_description,
152 $this->cur_spec_lang,
180 $a_data = str_replace([
"<",
">"], [
"<",
">"], $a_data);
183 $a_data = preg_replace(
"/\n/",
"", $a_data);
184 $a_data = preg_replace(
"/\t+/",
"", $a_data);
185 if (!empty($a_data)) {
186 $this->cdata .= $a_data;
handlerCharacterData($a_xml_parser, string $a_data)
setHandlers($a_xml_parser)
buildTag(string $type, string $name, ?array $attr=null)
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
handlerEndTag($a_xml_parser, string $a_name)
__construct(Container $dic, ilPlugin $plugin)
trimAndStripAttribs(array $attribs)
handlerBeginTag($a_xml_parser, string $a_name, array $a_attribs)
Class ilRbacAdmin Core functions for role based access control.
__construct(?string $path_to_file='', ?bool $throw_exception=false)
trimAndStrip(string $input)