ILIAS  release_8 Revision v8.24
ilWebResourceExporter Class Reference

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V. More...

+ Inheritance diagram for ilWebResourceExporter:
+ Collaboration diagram for ilWebResourceExporter:

Public Member Functions

 __construct ()
 Constructor. More...
 
 getXmlRepresentation (string $a_entity, string $a_schema_version, string $a_id)
 @inheritDoc More...
 
 getXmlExportTailDependencies (string $a_entity, string $a_target_release, array $a_ids)
 @inheritDoc More...
 
 getValidSchemaVersions (string $a_entity)
 @inheritDoc More...
 
 init ()
 
- Public Member Functions inherited from ilXmlExporter
 __construct ()
 
 setExport (ilExport $a_exp)
 
 getExport ()
 
 getXmlRepresentation (string $a_entity, string $a_schema_version, string $a_id)
 
 init ()
 
 setExportDirectories (string $a_dir_relative, string $a_dir_absolute)
 
 getRelativeExportDirectory ()
 
 getAbsoluteExportDirectory ()
 
 getXmlExportHeadDependencies (string $a_entity, string $a_target_release, array $a_ids)
 Get head dependencies. More...
 
 getXmlExportTailDependencies (string $a_entity, string $a_target_release, array $a_ids)
 Get tail dependencies. More...
 
 getValidSchemaVersions (string $a_entity)
 Returns schema versions that the component can export to. More...
 
 determineSchemaVersion (string $a_entity, string $a_target_release)
 

Protected Attributes

ilLogger $logger
 
- Protected Attributes inherited from ilXmlExporter
string $dir_relative = ""
 
string $dir_absolute = ""
 
ilExport $exp
 

Private Attributes

ilWebLinkXmlWriter $writer = null
 

Additional Inherited Members

- Static Public Member Functions inherited from ilXmlExporter
static lookupExportDirectory (string $a_obj_type, int $a_obj_id, string $a_export_type='xml', string $a_entity="")
 

Detailed Description

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V.

ILIAS is licensed with the GPL-3.0, see https://www.gnu.org/licenses/gpl-3.0.en.html You should have received a copy of said license along with the source code, too.

If this is not the case or you just want to try ILIAS, you'll find us at: https://www.ilias.de https://github.com/ILIAS-eLearning Booking definition

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

Definition at line 26 of file class.ilWebResourceExporter.php.

Constructor & Destructor Documentation

◆ __construct()

ilWebResourceExporter::__construct ( )

Constructor.

Reimplemented from ilXmlExporter.

Definition at line 35 of file class.ilWebResourceExporter.php.

36 {
37 global $DIC;
38
40 $this->logger = $DIC->logger()->webr();
41 }
global $DIC
Definition: feed.php:28
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc

References $DIC, ILIAS\GlobalScreen\Provider\__construct(), and ILIAS\Repository\logger().

+ Here is the call graph for this function:

Member Function Documentation

◆ getValidSchemaVersions()

ilWebResourceExporter::getValidSchemaVersions ( string  $a_entity)

@inheritDoc

Reimplemented from ilXmlExporter.

Definition at line 84 of file class.ilWebResourceExporter.php.

84 : array
85 {
86 return array(
87 "4.1.0" => array(
88 "namespace" => "http://www.ilias.de/Modules/WebResource/webr/4_1",
89 "xsd_file" => "ilias_webr_4_1.xsd",
90 "uses_dataset" => false,
91 "min" => "4.1.0",
92 "max" => ""
93 )
94 );
95 }

◆ getXmlExportTailDependencies()

ilWebResourceExporter::getXmlExportTailDependencies ( string  $a_entity,
string  $a_target_release,
array  $a_ids 
)

@inheritDoc

Reimplemented from ilXmlExporter.

Definition at line 65 of file class.ilWebResourceExporter.php.

69 : array {
70 $deps = [];
71 // service settings
72 $deps[] = [
73 "component" => "Services/Object",
74 "entity" => "common",
75 "ids" => $a_ids
76 ];
77
78 return $deps;
79 }

◆ getXmlRepresentation()

ilWebResourceExporter::getXmlRepresentation ( string  $a_entity,
string  $a_schema_version,
string  $a_id 
)

@inheritDoc

Reimplemented from ilXmlExporter.

Definition at line 46 of file class.ilWebResourceExporter.php.

50 : string {
51 try {
52 $this->writer = new ilWebLinkXmlWriter(false);
53 $this->writer->setObjId((int) $a_id);
54 $this->writer->write();
55 return $this->writer->xmlDumpMem(false);
56 } catch (UnexpectedValueException $e) {
57 $this->logger->warning("Caught error: " . $e->getMessage());
58 return '';
59 }
60 }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...

◆ init()

ilWebResourceExporter::init ( )

Reimplemented from ilXmlExporter.

Definition at line 97 of file class.ilWebResourceExporter.php.

97 : void
98 {
99 }

Field Documentation

◆ $logger

ilLogger ilWebResourceExporter::$logger
protected

Definition at line 30 of file class.ilWebResourceExporter.php.

◆ $writer

ilWebLinkXmlWriter ilWebResourceExporter::$writer = null
private

Definition at line 28 of file class.ilWebResourceExporter.php.


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