ILIAS  release_8 Revision v8.24
class.ilBibliographicExporter.php
Go to the documentation of this file.
1<?php
28{
29 protected ?\ilBibliographicDataSet $ds = null;
33 protected $db;
34
35
36 public function init(): void
37 {
38 global $DIC;
39 $ilDB = $DIC['ilDB'];
40 $this->ds = new ilBibliographicDataSet();
41 $this->ds->setDSPrefix('ds');
42 $this->db = $ilDB;
43 }
44
45
46 public function getValidSchemaVersions(string $a_entity): array
47 {
48 return array(
49 '4.5.0' => array(
50 'namespace' => 'http://www.ilias.de/Modules/DataCollection/dcl/4_5',
51 'xsd_file" => "ilias_dcl_4_5.xsd',
52 'uses_dataset' => true,
53 'min' => '4.5.0',
54 'max' => '',
55 ),
56 );
57 }
58
59
60 public function getXmlRepresentation(string $a_entity, string $a_schema_version, string $a_id): string
61 {
63 $this->ds->setExportDirectories($this->dir_relative, $this->dir_absolute);
64 $this->ds->exportLibraryFile($a_id);
65
66 return $this->ds->getXmlRepresentation($a_entity, $a_schema_version, [$a_id], '', true, true);
67 }
68
70 string $a_entity,
71 string $a_target_release,
72 array $a_ids
73 ) : array {
74 $res = [];
75 if ($a_entity == "bibl") {
76 $res[] = [
77 "component" => "Services/Object",
78 "entity" => "common",
79 "ids" => $a_ids
80 ];
81 }
82 return $res;
83 }
84}
Bibliographic dataset class.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
getValidSchemaVersions(string $a_entity)
Returns schema versions that the component can export to.
getXmlRepresentation(string $a_entity, string $a_schema_version, string $a_id)
getXmlExportTailDependencies(string $a_entity, string $a_target_release, array $a_ids)
Get tail dependencies.
static makeDirParents(string $a_dir)
Create a new directory and all parent directories.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
global $DIC
Definition: feed.php:28
$res
Definition: ltiservices.php:69