ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
ilContainerExporter Class Reference

container structure export More...

+ Inheritance diagram for ilContainerExporter:
+ Collaboration diagram for ilContainerExporter:

Public Member Functions

 __construct ()
 Constructor. More...
 
 init ()
 Init export. More...
 
 getXmlExportTailDependencies ($a_entity, $a_target_release, $a_ids)
 Get tail dependencies. More...
 
 getXmlRepresentation ($a_entity, $a_schema_version, $a_id)
 Get xml. More...
 
 getValidSchemaVersions ($a_entity)
 Returns schema versions that the component can export to. More...
 
- Public Member Functions inherited from ilXmlExporter
 __construct ()
 Constructor. More...
 
 setExport (ilExport $a_exp)
 Set export object. More...
 
 getExport ()
 Get export. More...
 
 getXmlRepresentation ($a_entity, $a_schema_version, $a_id)
 Get xml representation. More...
 
 init ()
 
 setExportDirectories ($a_dir_relative, $a_dir_absolute)
 Export directories. More...
 
 getRelativeExportDirectory ()
 Get relative export directory. More...
 
 getAbsoluteExportDirectory ()
 Get absolute export directory. More...
 
 getXmlExportHeadDependencies ($a_entity, $a_target_release, $a_ids)
 Get head dependencies. More...
 
 getXmlExportTailDependencies ($a_entity, $a_target_release, $a_ids)
 Get tail dependencies. More...
 
 getValidSchemaVersions ($a_entity)
 Returns schema versions that the component can export to. More...
 
 determineSchemaVersion ($a_entity, $a_target_release)
 Determine schema version. More...
 

Private Attributes

 $writer = null
 

Additional Inherited Members

- Static Public Member Functions inherited from ilXmlExporter
static lookupExportDirectory ($a_obj_type, $a_obj_id, $a_export_type='xml', $a_entity="")
 export directory lookup More...
 
- Protected Attributes inherited from ilXmlExporter
 $dir_relative
 
 $dir_absolute
 
 $exp
 

Detailed Description

container structure export

Author
Stefan Meyer meyer.nosp@m.@lei.nosp@m.fos.c.nosp@m.om
Version
$Id$

Definition at line 17 of file class.ilContainerExporter.php.

Constructor & Destructor Documentation

◆ __construct()

ilContainerExporter::__construct ( )

Constructor.

Reimplemented from ilXmlExporter.

Definition at line 24 of file class.ilContainerExporter.php.

25 {
26 }

Member Function Documentation

◆ getValidSchemaVersions()

ilContainerExporter::getValidSchemaVersions (   $a_entity)

Returns schema versions that the component can export to.

ILIAS chooses the first one, that has min/max constraints which fit to the target release. Please put the newest on top.

Returns

Reimplemented from ilXmlExporter.

Definition at line 135 of file class.ilContainerExporter.php.

136 {
137 return array(
138 "4.1.0" => array(
139 "namespace" => "http://www.ilias.de/Modules/Folder/fold/4_1",
140 "xsd_file" => "ilias_fold_4_1.xsd",
141 "uses_dataset" => false,
142 "min" => "4.1.0",
143 "max" => "")
144 );
145 }

◆ getXmlExportTailDependencies()

ilContainerExporter::getXmlExportTailDependencies (   $a_entity,
  $a_target_release,
  $a_ids 
)

Get tail dependencies.

Parameters
stringentity
stringtarget release
arrayids
Returns
array array of array with keys "component", entity", "ids"

Reimplemented from ilXmlExporter.

Definition at line 36 of file class.ilContainerExporter.php.

37 {
38 if ($a_entity != 'struct') {
39 return;
40 }
41
42
43 $res = array();
44
45 // pages
46
47 $pg_ids = array();
48
49 // container pages
50 include_once("./Services/Container/classes/class.ilContainerPage.php");
51 foreach ($a_ids as $id) {
52 if (ilContainerPage::_exists("cont", $id)) {
53 $pg_ids[] = "cont:" . $id;
54 }
55 }
56
57 // container start objects pages
58 include_once("./Services/Container/classes/class.ilContainerStartObjectsPage.php");
59 foreach ($a_ids as $id) {
61 $pg_ids[] = "cstr:" . $id;
62 }
63 }
64
65 if (sizeof($pg_ids)) {
66 $res[] = array(
67 "component" => "Services/COPage",
68 "entity" => "pg",
69 "ids" => $pg_ids
70 );
71 }
72
73 // style
74 $style_ids = array();
75 foreach ($a_ids as $id) {
76 include_once("./Services/Style/Content/classes/class.ilObjStyleSheet.php");
78 // see #24888
80 if ($style_id > 0) {
81 $style_ids[] = $style_id;
82 }
83 }
84 if (sizeof($style_ids)) {
85 $res[] = array(
86 "component" => "Services/Style",
87 "entity" => "sty",
88 "ids" => $style_ids
89 );
90 }
91
92 // service settings
93 $res[] = array(
94 "component" => "Services/Object",
95 "entity" => "common",
96 "ids" => $a_ids);
97
98 // news settings
99 $res[] = [
100 "component" => "Services/News",
101 "entity" => "news_settings",
102 "ids" => $a_ids
103 ];
104
105 return $res;
106 }
static lookupObjectStyle($a_obj_id)
Lookup object style.
static getEffectiveContentStyleId($a_style_id, $a_type="")
Get effective Style Id.
static _exists($a_parent_type, $a_id, $a_lang="", $a_no_cache=false)
Checks whether page exists.
if(!array_key_exists('StateId', $_REQUEST)) $id
foreach($_POST as $key=> $value) $res

References $id, $res, ilPageObject\_exists(), ilObjStyleSheet\getEffectiveContentStyleId(), and ilObjStyleSheet\lookupObjectStyle().

+ Here is the call graph for this function:

◆ getXmlRepresentation()

ilContainerExporter::getXmlRepresentation (   $a_entity,
  $a_schema_version,
  $a_id 
)

Get xml.

Parameters
object$a_entity
object$a_schema_version
object$a_id
Returns

Reimplemented from ilXmlExporter.

Definition at line 115 of file class.ilContainerExporter.php.

116 {
117 global $DIC;
118
119 $log = $DIC->logger()->root();
120 if ($a_entity == 'struct') {
121 $log->debug(__METHOD__ . ': Received id = ' . $a_id);
123 $writer->write();
124 return $writer->xmlDumpMem(false);
125 }
126 }
XML writer for container structure.
static _getAllReferences($a_id)
get all reference ids of object
$log
Definition: sabredav.php:21
global $DIC
Definition: saml.php:7

References $DIC, $log, $writer, and ilObject\_getAllReferences().

+ Here is the call graph for this function:

◆ init()

ilContainerExporter::init ( )

Init export.

Returns

Reimplemented from ilXmlExporter.

Definition at line 32 of file class.ilContainerExporter.php.

33 {
34 }

Field Documentation

◆ $writer

ilContainerExporter::$writer = null
private

Definition at line 19 of file class.ilContainerExporter.php.

Referenced by getXmlRepresentation().


The documentation for this class was generated from the following file: