39         $ilUser = $DIC[
'ilUser'];
    42         $this->user_id = $ilUser->getId();
    45     public function setMode(
int $a_mode): void
    47         $this->mode = $a_mode;
    57         $this->highlighter = $a_highlighter;
    67         $this->check_permission = $a_status;
    77         $this->user_id = $a_id;
    87         $this->enable_operations = $a_status;
    97         $this->enable_references = $a_stat;
   119         $ilAccess = $DIC[
'ilAccess'];
   120         $objDefinition = $DIC[
'objDefinition'];
   124             if (method_exists($object, 
'getType') &&
   126                 $objDefinition->isRBACObject($object->getType()) &&
   127                 !$ilAccess->checkAccessOfUser(
   135             $this->appendObject($object);
   146     private function appendObject(
ilObject $object): 
void   150         $tree = $DIC[
'tree'];
   151         $rbacreview = $DIC[
'rbacreview'];
   154         $objectDefinition = $DIC[
'objDefinition'];
   157         if ($object->
getType() === 
"role" && $rbacreview->isRoleDeleted(
$id)) {
   166         if ($objectDefinition->supportsOfflineHandling($object->
getType())) {
   187             if (!$tree->isInTree($ref_id)) {
   193                 'parent_id' => $tree->getParentId($ref_id)
   195             $attr[
'accessInfo'] = $this->
getAccessInfo($object, $ref_id);
   214         $tree = $DIC[
'tree'];
   216         if (!$tree->checkForParentType($a_ref_id, 
'crs')) {
   221         switch ($time_targets[
'timing_type']) {
   223                 $type = self::TIMING_TEMPORARILY_AVAILABLE;
   226                 $type = self::TIMING_PRESETTING;
   230                 $type = self::TIMING_DEACTIVATED;
   234         $this->
xmlStartTag(
'TimeTarget', array(
'type' => $type));
   236         $vis = (
int) $time_targets[
'visible'] === 0 ? self::TIMING_VISIBILITY_OFF : self::TIMING_VISIBILITY_ON;
   239             array(
'starting_time' => $time_targets[
'timing_start'],
   240                   'ending_time' => $time_targets[
'timing_end'],
   248                 'starting_time' => $time_targets[
'suggestion_start'],
   249                 'ending_time' => $time_targets[
'suggestion_end'],
   250                 'changeable' => $time_targets[
'changeable']
   263                 $size = $obj->getFileSize();
   264                 $extension = $obj->getFileExtension();
   266                 $this->
xmlElement(
"Property", array(
'name' => 
'fileSize'), (
string) $size);
   267                 $this->
xmlElement(
"Property", array(
'name' => 
'fileExtension'), (
string) $extension);
   270                     array(
'name' => 
'fileVersion'),
   271                     (
string) $obj->getVersion()
   282         $ilAccess = $DIC[
'ilAccess'];
   283         $rbacreview = $DIC[
'rbacreview'];
   284         $objDefinition = $DIC[
'objDefinition'];
   287             $ops = $rbacreview->getOperationsOnTypeString($a_type);
   288             if (is_array($ops)) {
   289                 foreach ($ops as $ops_id) {
   290                     $operation = $rbacreview->getOperation($ops_id);
   292                     if (count($operation) && $ilAccess->checkAccessOfUser(
   294                         $operation[
'operation'],
   298                         $this->
xmlElement(
'Operation', null, $operation[
'operation']);
   303             $objects = $objDefinition->getCreatableSubObjects($a_type);
   305             $creation_operations = array();
   306             foreach ($objects as $type => $info) {
   307                 $ops_id = $ops_ids[$type] ?? null;
   313                 $operation = $rbacreview->getOperation($ops_id);
   315                 if (count($operation) && $ilAccess->checkAccessOfUser(
   317                     $operation[
'operation'],
   321                     $this->
xmlElement(
'Operation', null, $operation[
'operation']);
   329         self::appendPathToObject($this, $refid);
   334         $this->
xmlSetDtdDef(
"<!DOCTYPE Objects PUBLIC \"-//ILIAS//DTD ILIAS Repositoryobjects//EN\" \"" . ILIAS_HTTP_PATH . 
"/components/ILIAS/Export/xml/ilias_object_4_0.dtd\">");
   349         $ilAccess = $DIC[
'ilAccess'];
   351         $ilAccess->checkAccessOfUser($this->
getUserId(), 
'read', 
'view', $ref_id, $object->
getType(), $object->
getId());
   353         if (!$info = $ilAccess->getInfo()) {
   357         return $info[0][
'type'];
   364         $tree = $DIC[
'tree'];
   366         $items = $tree->getPathFull($refid);
   368         foreach ($items as $item) {
   369             if ((
int) $item[
"ref_id"] === $refid) {
   372             if ($item[
"type"] === 
"root") {
   373                 $item[
"title"] = 
$lng->txt(
"repository");
   375             $writer->
xmlElement(
"Element", array(
"ref_id" => $item[
"ref_id"], 
"type" => $item[
"type"]), $item[
"title"]);
 
enableOperations(bool $a_status)
 
isPermissionCheckEnabled()
 
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
 
setHighlighter(ilLuceneHighlighterResultParser $a_highlighter)
 
const TIMING_VISIBILITY_OFF
 
static _getAllReferences(int $id)
get all reference ids for object ID 
 
const TIMINGS_DEACTIVATED
 
xmlSetGenCmt(string $genCmt)
Sets generated comment. 
 
getCreateDate()
Get create date in YYYY-MM-DD HH-MM-SS format. 
 
getAccessInfo(ilObject $object, int $ref_id)
 
xmlEndTag(string $tag)
Writes an endtag. 
 
static lookupCreateOperationIds(array $a_type_arr)
Lookup operation ids. 
 
xmlSetDtdDef(string $dtdDef)
Sets dtd definition. 
 
const TIMING_TEMPORARILY_AVAILABLE
 
ilLuceneHighlighterResultParser $highlighter
 
appendOperations(int $a_ref_id, string $a_type)
 
xmlHeader()
Writes xml header. 
 
const TIMING_VISIBILITY_ON
 
setObjects(array $objects)
 
static getItem(int $ref_id)
 
enablePermissionCheck(bool $a_status)
 
appendTimeTargets(int $a_ref_id)
Append time target settings for items inside of courses. 
 
$id
plugin.php for ilComponentBuildPluginInfoObjectiveTest::testAddPlugins 
 
__construct(Container $dic, ilPlugin $plugin)
 
xmlStartTag(string $tag, ?array $attrs=null, bool $empty=false, bool $encode=true, bool $escape=true)
Writes a starttag. 
 
appendObjectProperties(ilObject $obj)
 
xmlElement(string $tag, $attrs=null, $data=null, $encode=true, $escape=true)
Writes a basic element (no children, just textual content) 
 
getLastUpdateDate()
Get last update date in YYYY-MM-DD HH-MM-SS format. 
 
xmlDumpMem(bool $format=true)
Returns xml document from memory. 
 
static appendPathToObject(ilXmlWriter $writer, int $refid)
 
enableReferences(bool $a_stat)
 
XML writer class Class to simplify manual writing of xml documents.