TimeTrackerInitialization implements MiddlewareInterface
FinalYes
Initializes the time tracker (singleton) for the whole TYPO3 Frontend
Table of Contents
Interfaces
- MiddlewareInterface
Properties
Methods
- __construct() : mixed
- process() : ResponseInterface
- Starting time tracking (by setting up a singleton object)
- typoScriptDeterminedListener() : void
- This middleware is run pretty early in the FE chain to initialize correctly.
- isBackendUserCookieSet() : bool
- isDebugModeEnabled() : bool
Properties
$timeTracker read-only
protected
TimeTracker
$timeTracker
Methods
__construct()
public
__construct(TimeTracker $timeTracker) : mixed
Parameters
- $timeTracker : TimeTracker
process()
Starting time tracking (by setting up a singleton object)
public
process(ServerRequestInterface $request, RequestHandlerInterface $handler) : ResponseInterface
Parameters
- $request : ServerRequestInterface
- $handler : RequestHandlerInterface
Return values
ResponseInterfacetypoScriptDeterminedListener()
This middleware is run pretty early in the FE chain to initialize correctly.
public
typoScriptDeterminedListener(AfterTypoScriptDeterminedEvent $event) : void
It however should only add the response header if debugging is enabled in TypoScript 'config', which is not available in the incoming Request, yet. It thus listens on the AfterTypoScriptDeterminedEvent to set $this->isDebugEnabledInTypoScriptConfig.
Parameters
- $event : AfterTypoScriptDeterminedEvent
Attributes
- #[AsEventListener]
- 'typo3-frontend/timetracker-init-middleware'
isBackendUserCookieSet()
protected
isBackendUserCookieSet(ServerRequestInterface $request) : bool
Parameters
- $request : ServerRequestInterface
Return values
boolisDebugModeEnabled()
protected
isDebugModeEnabled() : bool