ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
ILIAS\Container\Page\PageManager Class Reference
+ Collaboration diagram for ILIAS\Container\Page\PageManager:

Public Member Functions

 __construct (\ilDBInterface $db, InternalDomainService $domain_service, \ILIAS\Style\Content\DomainService $content_style_domain, \ilContainer $container, ?string $lang=null)
 
 getHtml ()
 
 getDom ()
 

Protected Attributes

string $lang = null
 
InternalDomainService $domain_service
 
ilContainer $container
 
ILIAS Style Content DomainService $content_style_domain
 

Detailed Description

Author
Alexander Killing killi.nosp@m.ng@l.nosp@m.eifos.nosp@m..de

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

Constructor & Destructor Documentation

◆ __construct()

ILIAS\Container\Page\PageManager::__construct ( \ilDBInterface  $db,
InternalDomainService  $domain_service,
\ILIAS\Style\Content\DomainService  $content_style_domain,
\ilContainer  $container,
?string  $lang = null 
)

Definition at line 33 of file class.PageManager.php.

39 {
40 $this->content_style_domain = $content_style_domain;
41 $this->domain_service = $domain_service;
42 $this->container = $container;
43 $user = $this->domain_service->user();
44 if (is_null($lang)) {
45 $ot = $this->container->getObjectProperties()->getPropertyTranslations();
46 $this->lang = $ot->getEffectiveCOPageLang($user->getCurrentLanguage(), "cont");
47 } else {
48 $this->lang = $lang;
49 }
50 }
ILIAS Style Content DomainService $content_style_domain
InternalDomainService $domain_service

References ILIAS\Container\Page\PageManager\$container, ILIAS\Container\Page\PageManager\$content_style_domain, ILIAS\Container\Page\PageManager\$domain_service, ILIAS\Container\Page\PageManager\$lang, and ilObject\getObjectProperties().

+ Here is the call graph for this function:

Member Function Documentation

◆ getDom()

ILIAS\Container\Page\PageManager::getDom ( )

Definition at line 82 of file class.PageManager.php.

82 : ?\DOMDocument
83 {
84 $settings = $this->domain_service->settings();
85
86 if (!$settings->get("enable_cat_page_edit") || $this->container->filteredSubtree()) {
87 return null;
88 }
89
90 // if page does not exist, return nothing
92 "cont",
93 $this->container->getId(),
94 $this->lang
95 )) {
96 return null;
97 }
98
99 // get page object
100 $page_gui = new \ilContainerPageGUI($this->container->getId(), 0, $this->lang);
101 $page = $page_gui->getPageObject();
102 $page->buildDom();
103 return $page->getDomDoc();
104 }
static _existsAndNotEmpty(string $a_parent_type, int $a_id, string $a_lang="-")
checks whether page exists and is not empty (may return true on some empty pages)

References ilPageUtil\_existsAndNotEmpty().

+ Here is the call graph for this function:

◆ getHtml()

ILIAS\Container\Page\PageManager::getHtml ( )

Definition at line 52 of file class.PageManager.php.

52 : string
53 {
54 $settings = $this->domain_service->settings();
55
56 if (!$settings->get("enable_cat_page_edit") || $this->container->filteredSubtree()) {
57 return "";
58 }
59
60 // if page does not exist, return nothing
62 "cont",
63 $this->container->getId(),
64 $this->lang
65 )) {
66 return "";
67 }
68
69 // get page object
70 $page_gui = new \ilContainerPageGUI($this->container->getId(), 0, $this->lang);
71 $style = $this->content_style_domain->styleForRefId($this->container->getRefId());
72 $page_gui->setStyleId($style->getEffectiveStyleId());
73
74 $page_gui->setPresentationTitle("");
75 $page_gui->setTemplateOutput(false);
76 $page_gui->setHeader("");
77 $html = $page_gui->showPage();
78
79 return $html;
80 }

References ilPageUtil\_existsAndNotEmpty().

+ Here is the call graph for this function:

Field Documentation

◆ $container

ilContainer ILIAS\Container\Page\PageManager::$container
protected

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

Referenced by ILIAS\Container\Page\PageManager\__construct().

◆ $content_style_domain

ILIAS Style Content DomainService ILIAS\Container\Page\PageManager::$content_style_domain
protected

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

Referenced by ILIAS\Container\Page\PageManager\__construct().

◆ $domain_service

InternalDomainService ILIAS\Container\Page\PageManager::$domain_service
protected

Definition at line 29 of file class.PageManager.php.

Referenced by ILIAS\Container\Page\PageManager\__construct().

◆ $lang

string ILIAS\Container\Page\PageManager::$lang = null
protected

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

Referenced by ILIAS\Container\Page\PageManager\__construct().


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