ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
ilFolderExporter Class Reference

Folder export. More...

+ Inheritance diagram for ilFolderExporter:
+ Collaboration diagram for ilFolderExporter:

Public Member Functions

 init ()
 
 getXmlExportHeadDependencies (string $a_entity, string $a_target_release, array $a_ids)
 Get head dependencies. More...
 
 getXmlRepresentation (string $a_entity, string $a_schema_version, string $a_id)
 
 getValidSchemaVersions (string $a_entity)
 Returns schema versions that the component can export to. More...
 
- 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)
 

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="")
 
- Protected Attributes inherited from ilXmlExporter
ilExport $exp
 

Detailed Description

Folder export.

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

Definition at line 25 of file class.ilFolderExporter.php.

Member Function Documentation

◆ getValidSchemaVersions()

ilFolderExporter::getValidSchemaVersions ( string  $a_entity)

Returns schema versions that the component can export to.

ILIAS chooses the first one, that has min/max constraints which fit to the target release. Please put the newest on top. Example: return array ( "4.1.0" => array( "namespace" => "http://www.ilias.de/Services/MetaData/md/4_1", "xsd_file" => "ilias_md_4_1.xsd", "min" => "4.1.0", "max" => "") );

Reimplemented from ilXmlExporter.

Definition at line 57 of file class.ilFolderExporter.php.

57 : array
58 {
59 return [
60 "4.1.0" => [
61 "namespace" => "https://www.ilias.de/Modules/Folder/fold/4_1",
62 "xsd_file" => "ilias_fold_4_1.xsd",
63 "uses_dataset" => false,
64 "min" => "4.1.0",
65 "max" => ""
66 ]
67 ];
68 }

◆ getXmlExportHeadDependencies()

ilFolderExporter::getXmlExportHeadDependencies ( string  $a_entity,
string  $a_target_release,
array  $a_ids 
)

Get head dependencies.

Returns
array array of array with keys "component", entity", "ids"

Reimplemented from ilXmlExporter.

Definition at line 31 of file class.ilFolderExporter.php.

31 : array
32 {
33 // always trigger container because of co-page(s)
34 return [
35 [
36 'component' => 'components/ILIAS/Container',
37 'entity' => 'struct',
38 'ids' => $a_ids
39 ]
40 ];
41 }

◆ getXmlRepresentation()

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

Reimplemented from ilXmlExporter.

Definition at line 43 of file class.ilFolderExporter.php.

43 : string
44 {
45 try {
46 $writer = null;
47 $writer = new ilFolderXmlWriter(false);
48 $writer->setObjId((int) $a_id);
49 $writer->write();
50 return $writer->xmlDumpMem(false);
51 } catch (UnexpectedValueException $e) {
52 $GLOBALS['ilLog']->write("Caught error: " . $e->getMessage());
53 return '';
54 }
55 }
XML writer for folders.
$GLOBALS["DIC"]
Definition: wac.php:54

References Vendor\Package\$e, and $GLOBALS.

◆ init()

ilFolderExporter::init ( )

Reimplemented from ilXmlExporter.

Definition at line 27 of file class.ilFolderExporter.php.

27 : void
28 {
29 }

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