ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
class.ilHelpImporter.php
Go to the documentation of this file.
1 <?php
2 /* Copyright (c) 1998-2009 ILIAS open source, Extended GPL, see docs/LICENSE */
3 
4 include_once("./Services/Export/classes/class.ilXmlImporter.php");
5 
14 {
18  protected $config = null;
19 
23  public function init()
24  {
25  include_once("./Services/Help/classes/class.ilHelpDataSet.php");
26  $this->ds = new ilHelpDataSet();
27  $this->ds->setDSPrefix("ds");
28 
29  $this->config = $this->getImport()->getConfig("Services/Help");
30  $module_id = $this->config->getModuleId();
31  if ($module_id > 0) {
32  include_once("./Services/Export/classes/class.ilImport.php");
33  $this->getImport()->getMapping()->addMapping('Services/Help', 'help_module', 0, $module_id);
34  /* not needed anymore, we now get mapping from learning module
35  include_once("./Modules/LearningModule/classes/class.ilLMObject.php");
36  $chaps = ilLMObject::getObjectList($this->getId(), "st");
37  foreach ($chaps as $chap)
38  {
39  $chap_arr = explode("_", $chap["import_id"]);
40  $imp->getMapping()->addMapping('Services/Help', 'help_chap',
41  $chap_arr[count($chap_arr) - 1], $chap["obj_id"]);
42  }*/
43  }
44  }
45 
46 
53  public function importXmlRepresentation($a_entity, $a_id, $a_xml, $a_mapping)
54  {
55  include_once("./Services/DataSet/classes/class.ilDataSetImportParser.php");
57  $a_entity,
58  $this->getSchemaVersion(),
59  $a_xml,
60  $this->ds,
61  $a_mapping
62  );
63  }
64 }
getSchemaVersion()
Get schema version.
init()
Initialisation.
Help system data set class.
importXmlRepresentation($a_entity, $a_id, $a_xml, $a_mapping)
Import XML.
$config
ilHelpImporterConfig
Manifest parser for ILIAS standard export files.
getImport()
Get import.
Importer class for help.
$parser
Definition: BPMN2Parser.php:23
Xml importer class.