ILIAS  release_5-0 Revision 5.0.0-1144-gc4397b1f870
class.ilHelpExporter.php
Go to the documentation of this file.
1<?php
2/* Copyright (c) 1998-2012 ILIAS open source, Extended GPL, see docs/LICENSE */
3
4include_once("./Services/Export/classes/class.ilXmlExporter.php");
5
14{
15 private $ds;
16
20 function init()
21 {
22 include_once("./Services/Help/classes/class.ilHelpDataSet.php");
23 $this->ds = new ilHelpDataSet();
24 $this->ds->setExportDirectories($this->dir_relative, $this->dir_absolute);
25 $this->ds->setDSPrefix("ds");
26 }
27
36 function getXmlExportTailDependencies($a_entity, $a_target_release, $a_ids)
37 {
38 if ($a_target_release == "4.3.0")
39 {
40 if ($a_entity == "help")
41 {
42 $lm_node_ids = array();
43 include_once("./Modules/LearningModule/classes/class.ilLMObject.php");
44 foreach($a_ids as $lm_id)
45 {
46 $chaps = ilLMObject::getObjectList($lm_id, "st");
47 foreach ($chaps as $chap)
48 {
49 $lm_node_ids[] = $chap["obj_id"];
50 }
51 }
52
53 return array (
54 array(
55 "component" => "Services/Help",
56 "entity" => "help_map",
57 "ids" => $lm_node_ids),
58 array(
59 "component" => "Services/Help",
60 "entity" => "help_tooltip",
61 "ids" => $a_ids)
62 );
63 }
64 }
65
66 return array();
67 }
68
69
78 public function getXmlRepresentation($a_entity, $a_schema_version, $a_id)
79 {
80 return $this->ds->getXmlRepresentation($a_entity, $a_schema_version, $a_id, "", true, true);
81 }
82
90 function getValidSchemaVersions($a_entity)
91 {
92 return array (
93 "4.3.0" => array(
94 "namespace" => "http://www.ilias.de/Services/Help/help/4_3",
95 "xsd_file" => "ilias_help_4_3.xsd",
96 "uses_dataset" => true,
97 "min" => "4.3.0",
98 "max" => "")
99 );
100 }
101
102}
103
104?>
Help system data set class.
Exporter class for help system information.
init()
Initialisation.
getXmlExportTailDependencies($a_entity, $a_target_release, $a_ids)
Get tail dependencies.
getValidSchemaVersions($a_entity)
Returns schema versions that the component can export to.
getXmlRepresentation($a_entity, $a_schema_version, $a_id)
Get xml representation.
getObjectList($lm_id, $type="")
static
Xml Exporter class.