‪TYPO3CMS  ‪main
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;
27 
29 {
34  public function ‪getIdentifier(): string
35  {
36  return 'example-submodule';
37  }
38 
42  public function ‪getLabel(): string
43  {
44  return 'Example SubModule';
45  }
46 
50  public function ‪getContent(‪ModuleData $data): string
51  {
52  return 'content';
53  }
54 
58  public function ‪getSettings(): string
59  {
60  return 'settings';
61  }
62 
68  public function ‪onSubmit(array $configurationToSave, ServerRequestInterface $request): void {}
69 
70  public function ‪getDataToStore(ServerRequestInterface $request): ‪ModuleData
71  {
72  return new ‪ModuleData(['foo' => 'bar']);
73  }
74 }
‪TYPO3\CMS\Adminpanel\Tests\Unit\Fixtures\SubModuleFixture\getDataToStore
‪getDataToStore(ServerRequestInterface $request)
Definition: SubModuleFixture.php:70
‪TYPO3\CMS\Adminpanel\ModuleApi\DataProviderInterface
Definition: DataProviderInterface.php:30
‪TYPO3\CMS\Adminpanel\Tests\Unit\Fixtures\SubModuleFixture\getLabel
‪getLabel()
Definition: SubModuleFixture.php:42
‪TYPO3\CMS\Adminpanel\ModuleApi\ModuleSettingsProviderInterface
Definition: ModuleSettingsProviderInterface.php:34
‪TYPO3\CMS\Adminpanel\Tests\Unit\Fixtures\SubModuleFixture\getSettings
‪getSettings()
Definition: SubModuleFixture.php:58
‪TYPO3\CMS\Adminpanel\Tests\Unit\Fixtures\SubModuleFixture\onSubmit
‪onSubmit(array $configurationToSave, ServerRequestInterface $request)
Definition: SubModuleFixture.php:68
‪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
‪getIdentifier()
Definition: SubModuleFixture.php:34
‪TYPO3\CMS\Adminpanel\Tests\Unit\Fixtures\SubModuleFixture\getContent
‪getContent(ModuleData $data)
Definition: SubModuleFixture.php:50
‪TYPO3\CMS\Adminpanel\ModuleApi\OnSubmitActorInterface
Definition: OnSubmitActorInterface.php:27
‪TYPO3\CMS\Adminpanel\ModuleApi\ModuleData
Definition: ModuleData.php:26
‪TYPO3\CMS\Adminpanel\Tests\Unit\Fixtures
Definition: DisabledMainModuleFixture.php:18
‪TYPO3\CMS\Adminpanel\Tests\Unit\Fixtures\SubModuleFixture
Definition: SubModuleFixture.php:29