19declare(strict_types=1);
34 $this->add_header = $a_add_header;
40 $this->obj_id = $a_obj_id;
46 if ($this->add_header) {
49 $this->
xmlStartTag(
'Folder', [
'Id' => $this->folder->getId()]);
50 $this->
xmlElement(
'Title', [], $this->folder->getTitle());
51 $this->
xmlElement(
'Description', [], $this->folder->getDescription());
62 protected function init(): void
67 throw new UnexpectedValueException(
'No obj_id given: ');
70 throw new UnexpectedValueException(
'Invalid obj_id given: ' . $this->obj_id);
72 if ($this->folder->getType() !==
'fold') {
73 throw new UnexpectedValueException(
'Invalid obj_id given. Object is not of type folder');
static _exportContainerSortingSettings(ilXmlWriter $xml, int $obj_id)
sorting XML-export for all container objects
__construct(bool $a_add_header)
static getInstanceByObjId(?int $obj_id, bool $stop_on_error=true)
get an instance of an Ilias object by object id
Class ilObject Basic functions for all objects.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
xmlSetGenCmt(string $genCmt)
Sets generated comment.
xmlElement(string $tag, $attrs=null, $data=null, $encode=true, $escape=true)
Writes a basic element (no children, just textual content)
xmlHeader()
Writes xml header.
xmlEndTag(string $tag)
Writes an endtag.
xmlStartTag(string $tag, ?array $attrs=null, bool $empty=false, bool $encode=true, bool $escape=true)
Writes a starttag.
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc