‪TYPO3CMS  ‪main
TYPO3\CMS\Adminpanel\Controller\MainController Class Reference

Public Member Functions

 __construct (private readonly ModuleLoader $moduleLoader, private readonly UriBuilder $uriBuilder, private readonly RequestId $requestId,)
 
 initialize (ServerRequestInterface $request)
 
 render (ServerRequestInterface $request)
 
 storeData (ServerRequestInterface $request)
 

Protected Member Functions

 generateBackendUrl (string $route)
 
 initializeModules (ServerRequestInterface $request, array $modules)
 
 storeDataPerModule (ServerRequestInterface $request, array $modules, ModuleDataStorageCollection $data)
 
 getBackendUser ()
 

Protected Attributes

array $modules = []
 
array $adminPanelModuleConfiguration
 

Detailed Description

Main controller for the admin panel.

Note this is a "shared" / singleton object: Middleware AdminPanelInitiator instantiates the object and eventually calls initialize(). Later, AdminPanelRenderer calls render() on the same object.

Definition at line 48 of file MainController.php.

Constructor & Destructor Documentation

◆ __construct()

TYPO3\CMS\Adminpanel\Controller\MainController::__construct ( private readonly ModuleLoader  $moduleLoader,
private readonly UriBuilder  $uriBuilder,
private readonly RequestId  $requestId 
)

Definition at line 54 of file MainController.php.

References $GLOBALS.

Member Function Documentation

◆ generateBackendUrl()

TYPO3\CMS\Adminpanel\Controller\MainController::generateBackendUrl ( string  $route)
protected

Generate a url to a backend route

Definition at line 186 of file MainController.php.

Referenced by TYPO3\CMS\Adminpanel\Controller\MainController\render().

◆ getBackendUser()

TYPO3\CMS\Adminpanel\Controller\MainController::getBackendUser ( )
protected

Definition at line 236 of file MainController.php.

References $GLOBALS.

Referenced by TYPO3\CMS\Adminpanel\Controller\MainController\render().

◆ initialize()

TYPO3\CMS\Adminpanel\Controller\MainController::initialize ( ServerRequestInterface  $request)

◆ initializeModules()

TYPO3\CMS\Adminpanel\Controller\MainController::initializeModules ( ServerRequestInterface  $request,
array  $modules 
)
protected
Parameters
array<string,ModuleInterface>‪$modules

Definition at line 194 of file MainController.php.

References TYPO3\CMS\Adminpanel\Controller\MainController\$modules.

Referenced by TYPO3\CMS\Adminpanel\Controller\MainController\initialize().

◆ render()

TYPO3\CMS\Adminpanel\Controller\MainController::render ( ServerRequestInterface  $request)

◆ storeData()

TYPO3\CMS\Adminpanel\Controller\MainController::storeData ( ServerRequestInterface  $request)

Stores data for admin panel in cache - Called in PSR-15 Middleware

See also
‪\TYPO3\CMS\Adminpanel\Middleware\AdminPanelDataPersister

Definition at line 169 of file MainController.php.

References TYPO3\CMS\Adminpanel\Utility\StateUtility\isOpen(), and TYPO3\CMS\Adminpanel\Controller\MainController\storeDataPerModule().

◆ storeDataPerModule()

TYPO3\CMS\Adminpanel\Controller\MainController::storeDataPerModule ( ServerRequestInterface  $request,
array  $modules,
ModuleDataStorageCollection  $data 
)
protected

Member Data Documentation

◆ $adminPanelModuleConfiguration

array TYPO3\CMS\Adminpanel\Controller\MainController::$adminPanelModuleConfiguration
protected

Definition at line 52 of file MainController.php.

◆ $modules

array TYPO3\CMS\Adminpanel\Controller\MainController::$modules = []
protected