4include_once(
"./Services/DataSet/classes/class.ilDataSet.php");
 
   23        return array(
"4.1.0");
 
   34        return "http://www.ilias.de/xml/Modules/HTMLLearningModule/" . $a_entity;
 
   43    protected function getTypes($a_entity, $a_version)
 
   45        if ($a_entity == 
"htlm") {
 
   51                        "Description" => 
"text",
 
   52                        "StartFile" => 
"text",
 
   53                        "Dir" => 
"directory");
 
   64    public function readData($a_entity, $a_version, $a_ids, $a_field = 
"")
 
   68        if (!is_array($a_ids)) {
 
   69            $a_ids = array($a_ids);
 
   72        if ($a_entity == 
"htlm") {
 
   76                        " startfile start_file " .
 
   77                        " FROM file_based_lm JOIN object_data ON (file_based_lm.id = object_data.obj_id) " .
 
   79                        $ilDB->in(
"id", $a_ids, 
false, 
"integer"));
 
  102        include_once(
"./Modules/HTMLLearningModule/classes/class.ilObjFileBasedLM.php");
 
  104        $dir = $lm->getDataDirectory();
 
  105        $a_set[
"Dir"] = $dir;
 
  116    public function importRecord($a_entity, $a_types, $a_rec, $a_mapping, $a_schema_version)
 
  125                include_once(
"./Modules/HTMLLearningModule/classes/class.ilObjFileBasedLM.php");
 
  126                if ($new_id = $a_mapping->getMapping(
'Services/Container', 
'objs', $a_rec[
'Id'])) {
 
  130                    $newObj->setType(
"htlm");
 
  131                    $newObj->create(
true);
 
  134                $newObj->setTitle($a_rec[
"Title"]);
 
  135                $newObj->setDescription($a_rec[
"Description"]);
 
  136                $newObj->setStartFile($a_rec[
"StartFile"], 
true);
 
  137                $newObj->update(
true);
 
  138                $this->current_obj = $newObj;
 
  140                $dir = str_replace(
"..", 
"", $a_rec[
"Dir"]);
 
  143                    $target_dir = $newObj->getDataDirectory();
 
  147                $a_mapping->addMapping(
"Modules/HTMLLearningModule", 
"htlm", $a_rec[
"Id"], $newObj->getId());
 
  148                $a_mapping->addMapping(
 
  151                    $a_rec[
"Id"] . 
":0:htlm",
 
  152                    $newObj->getId() . 
":0:htlm" 
An exception for terminatinating execution or to throw for unit testing.
A dataset contains in data in a common structure that can be shared and transformed for different pur...
stripTags(array $rec, array $omit_keys=[])
getDirectDataFromQuery($a_query, $a_convert_to_leading_upper=true, $a_set=true)
Get data from query.This is a standard procedure, all db field names are directly mapped to abstract ...
getImportDirectory()
Get import directory.
HTML learning module data set class.
getSupportedVersions()
Get supported versions.
getDependencies($a_entity, $a_version, $a_rec, $a_ids)
Determine the dependent sets of data.
importRecord($a_entity, $a_types, $a_rec, $a_mapping, $a_schema_version)
Import record.
getTypes($a_entity, $a_version)
Get field types for entity.
readData($a_entity, $a_version, $a_ids, $a_field="")
Read data.
getXmlNamespace($a_entity, $a_schema_version)
Get xml namespace.
getXmlRecord($a_entity, $a_version, $a_set)
Get xml record.
File Based Learning Module (HTML) object.
static getInstanceByObjId($a_obj_id, $stop_on_error=true)
get an instance of an Ilias object by object id
static rCopy($a_sdir, $a_tdir, $preserveTimeAttributes=false)
Copies content of a directory $a_sdir recursively to a directory $a_tdir.