ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
ilBlogExporter Class Reference

Blog export definition. More...

+ Inheritance diagram for ilBlogExporter:
+ Collaboration diagram for ilBlogExporter:

Public Member Functions

 init ()
 
 getXmlExportTailDependencies ($a_entity, $a_target_release, $a_ids)
 
 getXmlRepresentation ($a_entity, $a_schema_version, $a_id)
 
 getValidSchemaVersions ($a_entity)
 
- Public Member Functions inherited from ilXmlExporter
 __construct ()
 Constructor. More...
 
 setExport (ilExport $a_exp)
 Set export object. More...
 
 getExport ()
 Get export. More...
 
 getXmlRepresentation ($a_entity, $a_schema_version, $a_id)
 Get xml representation. More...
 
 init ()
 
 setExportDirectories ($a_dir_relative, $a_dir_absolute)
 Export directories. More...
 
 getRelativeExportDirectory ()
 Get relative export directory. More...
 
 getAbsoluteExportDirectory ()
 Get absolute export directory. More...
 
 getXmlExportHeadDependencies ($a_entity, $a_target_release, $a_ids)
 Get head dependencies. More...
 
 getXmlExportTailDependencies ($a_entity, $a_target_release, $a_ids)
 Get tail dependencies. More...
 
 getValidSchemaVersions ($a_entity)
 Returns schema versions that the component can export to. More...
 
 determineSchemaVersion ($a_entity, $a_target_release)
 Determine schema version. More...
 

Protected Attributes

 $ds
 
- Protected Attributes inherited from ilXmlExporter
 $dir_relative
 
 $dir_absolute
 
 $exp
 

Additional Inherited Members

- Static Public Member Functions inherited from ilXmlExporter
static lookupExportDirectory ($a_obj_type, $a_obj_id, $a_export_type='xml', $a_entity="")
 export directory lookup More...
 

Detailed Description

Blog export definition.

Author
Jörg Lützenkirchen luetz.nosp@m.enki.nosp@m.rchen.nosp@m.@lei.nosp@m.fos.c.nosp@m.om
Version
$Id$

Definition at line 14 of file class.ilBlogExporter.php.

Member Function Documentation

◆ getValidSchemaVersions()

ilBlogExporter::getValidSchemaVersions (   $a_entity)

Definition at line 72 of file class.ilBlogExporter.php.

References array.

73  {
74  return array(
75  "4.3.0" => array(
76  "namespace" => "http://www.ilias.de/Modules/Blog/4_3",
77  "xsd_file" => "ilias_blog_4_3.xsd",
78  "uses_dataset" => true,
79  "min" => "4.3.0",
80  "max" => "4.9.9"),
81  "5.0.0" => array(
82  "namespace" => "http://www.ilias.de/Modules/Blog/5_0",
83  "xsd_file" => "ilias_blog_5_0.xsd",
84  "uses_dataset" => true,
85  "min" => "5.0.0",
86  "max" => "")
87 
88  );
89  }
Create styles array
The data for the language used.

◆ getXmlExportTailDependencies()

ilBlogExporter::getXmlExportTailDependencies (   $a_entity,
  $a_target_release,
  $a_ids 
)

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

References $id, $res, array, ilBlogPosting\getAllPostings(), and ilObjStyleSheet\lookupObjectStyle().

26  {
27  $res = array();
28 
29  // postings
30  include_once("./Modules/Blog/classes/class.ilBlogPosting.php");
31  $pg_ids = array();
32  foreach ($a_ids as $id) {
33  $pages = ilBlogPosting::getAllPostings($id);
34  foreach (array_keys($pages) as $p) {
35  $pg_ids[] = "blp:" . $p;
36  }
37  }
38  if (sizeof($pg_ids)) {
39  $res[] = array(
40  "component" => "Services/COPage",
41  "entity" => "pg",
42  "ids" => $pg_ids
43  );
44  }
45 
46  // style
47  $style_ids = array();
48  foreach ($a_ids as $id) {
49  include_once("./Services/Style/Content/classes/class.ilObjStyleSheet.php");
50  $style_id = ilObjStyleSheet::lookupObjectStyle($id);
51  if ($style_id > 0) {
52  $style_ids[] = $style_id;
53  }
54  }
55  if (sizeof($style_ids)) {
56  $res[] = array(
57  "component" => "Services/Style",
58  "entity" => "sty",
59  "ids" => $style_ids
60  );
61  }
62 
63  return $res;
64  }
if(!array_key_exists('StateId', $_REQUEST)) $id
static lookupObjectStyle($a_obj_id)
Lookup object style.
static getAllPostings($a_blog_id, $a_limit=1000, $a_offset=0)
Get all postings of blog.
foreach($_POST as $key=> $value) $res
Create styles array
The data for the language used.
+ Here is the call graph for this function:

◆ getXmlRepresentation()

ilBlogExporter::getXmlRepresentation (   $a_entity,
  $a_schema_version,
  $a_id 
)

Definition at line 66 of file class.ilBlogExporter.php.

67  {
68  $this->ds->setExportDirectories($this->dir_relative, $this->dir_absolute);
69  return $this->ds->getXmlRepresentation($a_entity, $a_schema_version, $a_id, "", true, true);
70  }

◆ init()

ilBlogExporter::init ( )

Definition at line 18 of file class.ilBlogExporter.php.

19  {
20  include_once("./Modules/Blog/classes/class.ilBlogDataSet.php");
21  $this->ds = new ilBlogDataSet();
22  $this->ds->setDSPrefix("ds");
23  }
Blog Data set class.

Field Documentation

◆ $ds

ilBlogExporter::$ds
protected

Definition at line 16 of file class.ilBlogExporter.php.


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