‪TYPO3CMS  10.4
SubModuleFixture.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 
20 use Psr\Http\Message\ServerRequestInterface;
28 use TYPO3\CMS\Adminpanel\Modules\AdminPanelSubModuleInterface;
29 
31 {
32 
38  public function ‪initializeModule(ServerRequestInterface $request): void
39  {
40  }
41 
48  public function ‪getIdentifier(): string
49  {
50  return 'example-submodule';
51  }
52 
58  public function ‪getLabel(): string
59  {
60  return 'Example SubModule';
61  }
62 
69  public function ‪getContent(‪ModuleData $data): string
70  {
71  return 'content';
72  }
73 
79  public function ‪getSettings(): string
80  {
81  return 'settings';
82  }
83 
92  public function ‪onSubmit(array $configurationToSave, ServerRequestInterface $request): void
93  {
94  }
95 
100  public function ‪getDataToStore(ServerRequestInterface $request): ‪ModuleData
101  {
102  return new ‪ModuleData(['foo' => 'bar']);
103  }
104 }
‪TYPO3\CMS\Adminpanel\Tests\Unit\Fixtures\SubModuleFixture\getLabel
‪string getLabel()
Definition: SubModuleFixture.php:58
‪TYPO3\CMS\Adminpanel\ModuleApi\InitializableInterface
Definition: InitializableInterface.php:36
‪TYPO3\CMS\Adminpanel\Tests\Unit\Fixtures\SubModuleFixture\getSettings
‪string getSettings()
Definition: SubModuleFixture.php:79
‪TYPO3\CMS\Adminpanel\ModuleApi\DataProviderInterface
Definition: DataProviderInterface.php:30
‪TYPO3\CMS\Adminpanel\Tests\Unit\Fixtures\SubModuleFixture\initializeModule
‪initializeModule(ServerRequestInterface $request)
Definition: SubModuleFixture.php:38
‪TYPO3\CMS\Adminpanel\ModuleApi\ModuleSettingsProviderInterface
Definition: ModuleSettingsProviderInterface.php:34
‪TYPO3\CMS\Adminpanel\Tests\Unit\Fixtures\SubModuleFixture\onSubmit
‪onSubmit(array $configurationToSave, ServerRequestInterface $request)
Definition: SubModuleFixture.php:92
‪TYPO3\CMS\Adminpanel\ModuleApi\ModuleInterface
Definition: ModuleInterface.php:26
‪TYPO3\CMS\Adminpanel\ModuleApi\ContentProviderInterface
Definition: ContentProviderInterface.php:30
‪TYPO3\CMS\Adminpanel\Tests\Unit\Fixtures\SubModuleFixture\getIdentifier
‪string getIdentifier()
Definition: SubModuleFixture.php:48
‪TYPO3\CMS\Adminpanel\Tests\Unit\Fixtures\SubModuleFixture\getDataToStore
‪TYPO3 CMS Adminpanel ModuleApi ModuleData getDataToStore(ServerRequestInterface $request)
Definition: SubModuleFixture.php:100
‪TYPO3\CMS\Adminpanel\ModuleApi\OnSubmitActorInterface
Definition: OnSubmitActorInterface.php:27
‪TYPO3\CMS\Adminpanel\ModuleApi\ModuleData
Definition: ModuleData.php:27
‪TYPO3\CMS\Adminpanel\Tests\Unit\Fixtures
Definition: DisabledMainModuleFixture.php:18
‪TYPO3\CMS\Adminpanel\Tests\Unit\Fixtures\SubModuleFixture\getContent
‪string getContent(ModuleData $data)
Definition: SubModuleFixture.php:69
‪TYPO3\CMS\Adminpanel\Tests\Unit\Fixtures\SubModuleFixture
Definition: SubModuleFixture.php:31