‪TYPO3CMS  ‪main
AvailableActionsForExtensionEvent.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 {
28  private array ‪$actions;
29 
30  public function ‪__construct(
31  private readonly string $packageKey,
32  private readonly array $packageData,
33  array ‪$actions
34  ) {
35  $this->actions = ‪$actions;
36  }
37 
38  public function ‪getPackageKey(): string
39  {
40  return $this->packageKey;
41  }
42 
43  public function ‪getPackageData(): array
44  {
45  return $this->packageData;
46  }
47 
48  public function ‪getActions(): array
49  {
50  return ‪$this->actions;
51  }
52 
53  public function ‪addAction(string $actionKey, string $content): void
54  {
55  $this->actions[$actionKey] = $content;
56  }
57 
58  public function ‪setActions(array ‪$actions): void
59  {
60  $this->actions = ‪$actions;
61  }
62 }
‪TYPO3\CMS\Extensionmanager\Event
Definition: AvailableActionsForExtensionEvent.php:18
‪TYPO3\CMS\Extensionmanager\Event\AvailableActionsForExtensionEvent\addAction
‪addAction(string $actionKey, string $content)
Definition: AvailableActionsForExtensionEvent.php:53
‪TYPO3\CMS\Extensionmanager\Event\AvailableActionsForExtensionEvent\$actions
‪array $actions
Definition: AvailableActionsForExtensionEvent.php:28
‪TYPO3\CMS\Extensionmanager\Event\AvailableActionsForExtensionEvent\getActions
‪getActions()
Definition: AvailableActionsForExtensionEvent.php:48
‪TYPO3\CMS\Extensionmanager\Event\AvailableActionsForExtensionEvent
Definition: AvailableActionsForExtensionEvent.php:24
‪TYPO3\CMS\Extensionmanager\Event\AvailableActionsForExtensionEvent\setActions
‪setActions(array $actions)
Definition: AvailableActionsForExtensionEvent.php:58
‪TYPO3\CMS\Extensionmanager\Event\AvailableActionsForExtensionEvent\getPackageData
‪getPackageData()
Definition: AvailableActionsForExtensionEvent.php:43
‪TYPO3\CMS\Extensionmanager\Event\AvailableActionsForExtensionEvent\__construct
‪__construct(private readonly string $packageKey, private readonly array $packageData, array $actions)
Definition: AvailableActionsForExtensionEvent.php:30
‪TYPO3\CMS\Extensionmanager\Event\AvailableActionsForExtensionEvent\getPackageKey
‪getPackageKey()
Definition: AvailableActionsForExtensionEvent.php:38