ILIAS  trunk Revision v12.0_alpha-1540-g00f839d5fa1
class.InternalDomainService.php
Go to the documentation of this file.
1<?php
2
19declare(strict_types=1);
20
21namespace ILIAS\COPage;
22
31
36{
37 use GlobalDICDomainServices;
38
39 protected ?\ilLogger $copg_log = null;
42
43 public function __construct(
47 ) {
48 $this->repo_service = $repo_service;
49 $this->data_service = $data_service;
50 $this->initDomainServices($DIC);
51 }
52
53 public function pc(?PCDefinition $def = null): PC\DomainService
54 {
55 return new PC\DomainService(
56 $this->data_service,
57 $this->repo_service,
58 $this,
59 $def
60 );
61 }
62
63 public function history(): History\HistoryManager
64 {
65 return new History\HistoryManager(
66 $this->data_service,
67 $this->repo_service,
68 $this
69 );
70 }
71
72 public function historyRetrieval(int $page_id, string $parent_type, string $lang): History\HistoryRetrieval
73 {
74 return new History\HistoryRetrieval(
75 $this->repo_service->history(),
76 $this->DIC->database(),
77 $page_id,
78 $parent_type,
79 $lang
80 );
81 }
82
83 public function xsl(): Xsl\XslManager
84 {
85 return new Xsl\XslManager();
86 }
87
88 public function domUtil(): Dom\DomUtil
89 {
90 return new Dom\DomUtil();
91 }
92
93 public function page(): Page\PageManagerInterface
94 {
95 return new Page\PageManager();
96 }
97
98 public function pageConfig(string $parent_type): \ilPageConfig
99 {
101 $class = $def["class_name"] . "Config";
102 $cfg = new $class();
103 return $cfg;
104 }
105
106 public function htmlTransformUtil(): Html\TransformUtil
107 {
108 return new Html\TransformUtil();
109 }
110
111 public function contentIds(\ilPageObject $page): ID\ContentIdManager
112 {
113 return new ID\ContentIdManager($page);
114 }
115
116 public function contentIdGenerator(): ID\ContentIdGenerator
117 {
118 return new ID\ContentIdGenerator();
119 }
120
121 public function compare(): PageCompare
122 {
123 return new PageCompare();
124 }
125
126 public function link(): LinkManager
127 {
128 return new LinkManager();
129 }
130
131 public function style(): StyleManager
132 {
133 return new StyleManager();
134 }
135
136 public function log(): ?\ilLogger
137 {
138 if (isset($this->DIC["ilLoggerFactory"])) {
139 if (is_null($this->copg_log)) {
140 $this->copg_log = $this->logger()->copg();
141 }
142 return $this->copg_log;
143 }
144 return null;
145 }
146
147 public function layoutRetrieval(): Layout\PageLayoutRetrieval
148 {
149 return new Layout\PageLayoutRetrieval();
150 }
151
152 public function testQuestion(): \ILIAS\TestQuestionPool\Questions\PublicInterface
153 {
154 return $this->DIC->testQuestion();
155 }
156}
Repository internal data service.
historyRetrieval(int $page_id, string $parent_type, string $lang)
__construct(Container $DIC, InternalRepoService $repo_service, InternalDataService $data_service)
Repository internal repo service.
Customizing of pimple-DIC for ILIAS.
Definition: Container.php:36
static getDefinitionByParentType(string $a_parent_type)
Get definition by parent type.
Component logger with individual log levels by component id.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
Class ilPageObject Handles PageObjects of ILIAS Learning Modules (see ILIAS DTD)
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
initDomainServices(\ILIAS\DI\Container $DIC)
Interface Observer \BackgroundTasks Contains several chained tasks and infos about them.
global $DIC
Definition: shib_login.php:26