ILIAS  release_6 Revision v6.24-5-g0c8bfefb3b8
ILIAS\UICore\PageContentProvider Class Reference

Class ilPageContentProvider. More...

+ Inheritance diagram for ILIAS\UICore\PageContentProvider:
+ Collaboration diagram for ILIAS\UICore\PageContentProvider:

Public Member Functions

 isInterestedInContexts ()
 
 getContentModification (CalledContexts $screen_context_stack)
 
 getTitleModification (CalledContexts $screen_context_stack)
 
 getShortTitleModification (CalledContexts $screen_context_stack)
 
 getViewTitleModification (CalledContexts $screen_context_stack)
 
 getFooterModification (CalledContexts $screen_context_stack)
 
- Public Member Functions inherited from ILIAS\GlobalScreen\Scope\Layout\Provider\AbstractModificationProvider
 __construct (Container $dic)
 
 getContentModification (CalledContexts $screen_context_stack)
 
 getLogoModification (CalledContexts $screen_context_stack)
 
 getResponsiveLogoModification (CalledContexts $screen_context_stack)
 
 getMainBarModification (CalledContexts $screen_context_stack)
 
 getMetaBarModification (CalledContexts $screen_context_stack)
 
 getBreadCrumbsModification (CalledContexts $screen_context_stack)
 
 getFooterModification (CalledContexts $screen_context_stack)
 
 getPageBuilderDecorator (CalledContexts $screen_context_stack)
 
 getTitleModification (CalledContexts $screen_context_stack)
 
 getShortTitleModification (CalledContexts $screen_context_stack)
 
 getViewTitleModification (CalledContexts $screen_context_stack)
 
- Public Member Functions inherited from ILIAS\GlobalScreen\Provider\AbstractProvider
 __construct (Container $dic)
 
 getFullyQualifiedClassName ()
 
 getProviderNameForPresentation ()
 

Static Public Member Functions

static setContent (string $content)
 
static setTitle (string $title)
 
static setShortTitle (string $short_title)
 
static setViewTitle (string $view_title)
 
static setPermaLink (string $perma_link)
 

Static Private Attributes

static $content = ""
 
static $perma_link = ""
 
static $title = ""
 
static $short_title = ""
 
static $view_title = ""
 

Additional Inherited Members

- Protected Member Functions inherited from ILIAS\GlobalScreen\Provider\AbstractProvider
 globalScreen ()
 
- Protected Attributes inherited from ILIAS\GlobalScreen\Scope\Layout\Provider\AbstractModificationProvider
 $context_collection
 
 $factory
 
- Protected Attributes inherited from ILIAS\GlobalScreen\Provider\AbstractProvider
 $dic
 

Detailed Description

Class ilPageContentProvider.

Author
Fabian Schmid fs@st.nosp@m.uder.nosp@m.-raim.nosp@m.ann..nosp@m.ch

Definition at line 21 of file PageContentProvider.php.

Member Function Documentation

◆ getContentModification()

ILIAS\UICore\PageContentProvider::getContentModification ( CalledContexts  $screen_context_stack)

Implements ILIAS\GlobalScreen\Scope\Layout\Provider\ModificationProvider.

Definition at line 99 of file PageContentProvider.php.

References ILIAS\UICore\PageContentProvider\$content, and ILIAS\GlobalScreen\Provider\AbstractProvider\globalScreen().

99  : ?ContentModification
100  {
101  return $this->globalScreen()->layout()->factory()->content()->withModification(function (Legacy $content) : Legacy {
102  $ui = $this->dic->ui();
103  return $ui->factory()->legacy(
104  $ui->renderer()->render($content) . self::$content
105  );
106  })->withLowPriority();
107  }
+ Here is the call graph for this function:

◆ getFooterModification()

ILIAS\UICore\PageContentProvider::getFooterModification ( CalledContexts  $screen_context_stack)

Implements ILIAS\GlobalScreen\Scope\Layout\Provider\ModificationProvider.

Definition at line 140 of file PageContentProvider.php.

References Vendor\Package\$f, ilObjLanguageAccess\_checkTranslate(), ilLink\_getStaticLink(), ilObjLanguageAccess\_getTranslationLink(), ilObjLanguageAccess\_isPageTranslation(), ilSystemSupportContactsGUI\getFooterLink(), ilAccessibilitySupportContactsGUI\getFooterLink(), ilAccessibilityControlConceptGUI\getFooterLink(), ilSystemSupportContactsGUI\getFooterText(), ilAccessibilitySupportContactsGUI\getFooterText(), ilAccessibilityControlConceptGUI\getFooterText(), ILIAS\GlobalScreen\Provider\AbstractProvider\globalScreen(), and ilImprint\isActive().

140  : ?FooterModification
141  {
142  return $this->globalScreen()->layout()->factory()->footer()->withModification(function () : Footer {
143  $f = $this->dic->ui()->factory();
144 
145  $links = [];
146  // ILIAS Version and Text
147  $ilias_version = $this->dic->settings()->get('ilias_version');
148  $text = "powered by ILIAS (v{$ilias_version})";
149 
150  // Imprint
151  if ($_REQUEST["baseClass"] !== "ilImprintGUI" && \ilImprint::isActive()) {
152  $imprint_title = $this->dic->language()->txt("imprint");
153  $imprint_url = \ilLink::_getStaticLink(0, "impr");
154  $links[] = $f->link()->standard($imprint_title, $imprint_url);
155  }
156 
157  // system support contacts
158  if (($system_support_url = \ilSystemSupportContactsGUI::getFooterLink()) !== '') {
159  $system_support_title = \ilSystemSupportContactsGUI::getFooterText();
160  $links[] = $f->link()->standard($system_support_title, $system_support_url);
161  }
162 
163  // output translation link
165  $translation_url = \ilObjLanguageAccess::_getTranslationLink();
166  $translation_title = $this->dic->language()->txt('translation');
167  $links[] = $f->link()->standard($translation_title, $translation_url)->withOpenInNewViewport(true);
168  }
169 
170  // accessibility control concept
171  if (($accessibility_control_url = \ilAccessibilityControlConceptGUI::getFooterLink()) !== '') {
172  $accessibility_control_title = \ilAccessibilityControlConceptGUI::getFooterText();
173  $links[] = $f->link()->standard($accessibility_control_title, $accessibility_control_url);
174  }
175 
176  // report accessibility issue
177  if (($accessibility_report_url = \ilAccessibilitySupportContactsGUI::getFooterLink()) !== '') {
178  $accessibility_report_title = \ilAccessibilitySupportContactsGUI::getFooterText();
179  $links[] = $f->link()->standard($accessibility_report_title, $accessibility_report_url);
180  }
181 
182  $footer = $f->mainControls()->footer($links, $text);
183 
184  if (self::$perma_link !== "") {
185  $footer = $footer->withPermanentURL(new URI(self::$perma_link));
186  }
187 
188  return $footer;
189  });
190  }
static _isPageTranslation()
Check if the current request is a page translation.
static _getTranslationLink()
Get the link to translate the current page.
static _checkTranslate()
Permission check for translations.
static isActive()
+ Here is the call graph for this function:

◆ getShortTitleModification()

ILIAS\UICore\PageContentProvider::getShortTitleModification ( CalledContexts  $screen_context_stack)
Parameters
CalledContexts$screen_context_stack
Returns
ShortTitleModification|null

Implements ILIAS\GlobalScreen\Scope\Layout\Provider\ModificationProvider.

Definition at line 119 of file PageContentProvider.php.

References ILIAS\UICore\PageContentProvider\$content, and ILIAS\GlobalScreen\Provider\AbstractProvider\globalScreen().

119  : ?ShortTitleModification
120  {
121  return $this->globalScreen()->layout()->factory()->short_title()->withModification(
122  function (string $content) : string {
123  return self::$short_title;
124  }
125  )->withLowPriority();
126  }
+ Here is the call graph for this function:

◆ getTitleModification()

ILIAS\UICore\PageContentProvider::getTitleModification ( CalledContexts  $screen_context_stack)
Parameters
CalledContexts$screen_context_stack
Returns
TitleModification|null

Implements ILIAS\GlobalScreen\Scope\Layout\Provider\ModificationProvider.

Definition at line 110 of file PageContentProvider.php.

References ILIAS\UICore\PageContentProvider\$content, and ILIAS\GlobalScreen\Provider\AbstractProvider\globalScreen().

110  : ?TitleModification
111  {
112  return $this->globalScreen()->layout()->factory()->title()->withModification(
113  function (string $content) : string {
114  return self::$title;
115  }
116  )->withLowPriority();
117  }
+ Here is the call graph for this function:

◆ getViewTitleModification()

ILIAS\UICore\PageContentProvider::getViewTitleModification ( CalledContexts  $screen_context_stack)
Parameters
CalledContexts$screen_context_stack
Returns
ViewTitleModification|null

Implements ILIAS\GlobalScreen\Scope\Layout\Provider\ModificationProvider.

Definition at line 128 of file PageContentProvider.php.

References ILIAS\UICore\PageContentProvider\$content, and ILIAS\GlobalScreen\Provider\AbstractProvider\globalScreen().

128  : ?ViewTitleModification
129  {
130  return $this->globalScreen()->layout()->factory()->view_title()->withModification(
131  function (string $content) : string {
132  return self::$view_title;
133  }
134  )->withLowPriority();
135  }
+ Here is the call graph for this function:

◆ isInterestedInContexts()

ILIAS\UICore\PageContentProvider::isInterestedInContexts ( )

Implements ILIAS\GlobalScreen\ScreenContext\ScreenContextAwareProvider.

Definition at line 90 of file PageContentProvider.php.

References ILIAS\GlobalScreen\ScreenContext\Stack\ContextCollection\main().

90  : ContextCollection
91  {
92  return $this->context_collection->main();
93  }
+ Here is the call graph for this function:

◆ setContent()

static ILIAS\UICore\PageContentProvider::setContent ( string  $content)
static
Parameters
string$content

Definition at line 48 of file PageContentProvider.php.

References ILIAS\UICore\PageContentProvider\$content.

48  : void
49  {
50  self::$content = $content;
51  }

◆ setPermaLink()

static ILIAS\UICore\PageContentProvider::setPermaLink ( string  $perma_link)
static
Parameters
string$perma_link

Definition at line 81 of file PageContentProvider.php.

References ILIAS\UICore\PageContentProvider\$perma_link.

81  : void
82  {
83  self::$perma_link = $perma_link;
84  }

◆ setShortTitle()

static ILIAS\UICore\PageContentProvider::setShortTitle ( string  $short_title)
static
Parameters
string$content

Definition at line 64 of file PageContentProvider.php.

References ILIAS\UICore\PageContentProvider\$short_title.

64  : void
65  {
66  self::$short_title = $short_title;
67  }

◆ setTitle()

static ILIAS\UICore\PageContentProvider::setTitle ( string  $title)
static
Parameters
string$content

Definition at line 56 of file PageContentProvider.php.

References ILIAS\UICore\PageContentProvider\$title.

56  : void
57  {
58  self::$title = $title;
59  }

◆ setViewTitle()

static ILIAS\UICore\PageContentProvider::setViewTitle ( string  $view_title)
static
Parameters
string$content

Definition at line 72 of file PageContentProvider.php.

References ILIAS\UICore\PageContentProvider\$view_title.

72  : void
73  {
74  self::$view_title = $view_title;
75  }

Field Documentation

◆ $content

◆ $perma_link

ILIAS\UICore\PageContentProvider::$perma_link = ""
staticprivate

◆ $short_title

ILIAS\UICore\PageContentProvider::$short_title = ""
staticprivate

◆ $title

ILIAS\UICore\PageContentProvider::$title = ""
staticprivate

Definition at line 35 of file PageContentProvider.php.

Referenced by ILIAS\UICore\PageContentProvider\setTitle().

◆ $view_title

ILIAS\UICore\PageContentProvider::$view_title = ""
staticprivate

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