‪TYPO3CMS  ‪main
InfoModule.php
Go to the documentation of this file.
1 <?php
2 
3 declare(strict_types=1);
4 
5 /*
6  * This file is part of the TYPO3 CMS project.
7  *
8  * It is free software; you can redistribute it and/or modify it under
9  * the terms of the GNU General Public License, either version 2
10  * of the License, or any later version.
11  *
12  * For the full copyright and license information, please read the
13  * LICENSE.txt file that was distributed with this source code.
14  *
15  * The TYPO3 project - inspiring people to share!
16  */
17 
19 
24 
29 {
30  public function ‪getIconIdentifier(): string
31  {
32  return 'actions-document-info';
33  }
34 
35  public function ‪getIdentifier(): string
36  {
37  return 'info';
38  }
39 
40  public function ‪getLabel(): string
41  {
42  return $this->‪getLanguageService()->sL(
43  'LLL:EXT:adminpanel/Resources/Private/Language/locallang_info.xlf:module.label'
44  );
45  }
46 
47  public function ‪getShortInfo(): string
48  {
49  $phpInformation = $this->moduleData->offsetGet($this->subModules['info_php']);
50  $parseTime = $this->‪getTimeTracker()->getParseTime();
51  return sprintf(
52  $this->‪getLanguageService()->sL(
53  'LLL:EXT:adminpanel/Resources/Private/Language/locallang_info.xlf:module.shortinfoLoadAndMemory'
54  ),
55  $parseTime,
56  $phpInformation['general']['Peak Memory Usage']
57  );
58  }
59 
60  protected function ‪getTimeTracker(): ‪TimeTracker
61  {
62  return GeneralUtility::makeInstance(TimeTracker::class);
63  }
64 }
‪TYPO3\CMS\Adminpanel\Modules\InfoModule\getTimeTracker
‪getTimeTracker()
Definition: InfoModule.php:60
‪TYPO3\CMS\Adminpanel\ModuleApi\AbstractModule
Definition: AbstractModule.php:29
‪TYPO3\CMS\Adminpanel\Modules\InfoModule\getIdentifier
‪getIdentifier()
Definition: InfoModule.php:35
‪TYPO3\CMS\Adminpanel\Modules\InfoModule
Definition: InfoModule.php:29
‪TYPO3\CMS\Adminpanel\ModuleApi\AbstractModule\getLanguageService
‪getLanguageService()
Definition: AbstractModule.php:95
‪TYPO3\CMS\Adminpanel\Modules\InfoModule\getIconIdentifier
‪getIconIdentifier()
Definition: InfoModule.php:30
‪TYPO3\CMS\Adminpanel\ModuleApi\ShortInfoProviderInterface
Definition: ShortInfoProviderInterface.php:30
‪TYPO3\CMS\Adminpanel\Modules\InfoModule\getShortInfo
‪getShortInfo()
Definition: InfoModule.php:47
‪TYPO3\CMS\Adminpanel\Modules\InfoModule\getLabel
‪getLabel()
Definition: InfoModule.php:40
‪TYPO3\CMS\Adminpanel\Modules
Definition: CacheModule.php:18
‪TYPO3\CMS\Core\Utility\GeneralUtility
Definition: GeneralUtility.php:52
‪TYPO3\CMS\Core\TimeTracker\TimeTracker
Definition: TimeTracker.php:34