‪TYPO3CMS  ‪main
AfterTemplatesHaveBeenDeterminedEvent.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;
22 
29 {
30  public function ‪__construct(
31  private readonly array $rootline,
32  private readonly ?ServerRequestInterface $request,
33  private array $templateRows,
34  ) {}
35 
36  public function ‪getRootline(): array
37  {
38  return $this->rootline;
39  }
40 
41  public function ‪getRequest(): ?ServerRequestInterface
42  {
43  return $this->request;
44  }
45 
49  public function ‪getSite(): ?‪SiteInterface
50  {
51  return $this->request?->getAttribute('site');
52  }
53 
54  public function ‪getTemplateRows(): array
55  {
56  return $this->templateRows;
57  }
58 
59  public function ‪setTemplateRows(array $templateRows): void
60  {
61  $this->templateRows = $templateRows;
62  }
63 }
‪TYPO3\CMS\Core\Site\Entity\SiteInterface
Definition: SiteInterface.php:26
‪TYPO3\CMS\Core\TypoScript\IncludeTree\Event\AfterTemplatesHaveBeenDeterminedEvent\setTemplateRows
‪setTemplateRows(array $templateRows)
Definition: AfterTemplatesHaveBeenDeterminedEvent.php:59
‪TYPO3\CMS\Core\TypoScript\IncludeTree\Event\AfterTemplatesHaveBeenDeterminedEvent\getTemplateRows
‪getTemplateRows()
Definition: AfterTemplatesHaveBeenDeterminedEvent.php:54
‪TYPO3\CMS\Core\TypoScript\IncludeTree\Event\AfterTemplatesHaveBeenDeterminedEvent\__construct
‪__construct(private readonly array $rootline, private readonly ?ServerRequestInterface $request, private array $templateRows,)
Definition: AfterTemplatesHaveBeenDeterminedEvent.php:30
‪TYPO3\CMS\Core\TypoScript\IncludeTree\Event\AfterTemplatesHaveBeenDeterminedEvent\getRootline
‪getRootline()
Definition: AfterTemplatesHaveBeenDeterminedEvent.php:36
‪TYPO3\CMS\Core\TypoScript\IncludeTree\Event\AfterTemplatesHaveBeenDeterminedEvent
Definition: AfterTemplatesHaveBeenDeterminedEvent.php:29
‪TYPO3\CMS\Core\TypoScript\IncludeTree\Event\AfterTemplatesHaveBeenDeterminedEvent\getRequest
‪getRequest()
Definition: AfterTemplatesHaveBeenDeterminedEvent.php:41
‪TYPO3\CMS\Core\TypoScript\IncludeTree\Event
Definition: AfterTemplatesHaveBeenDeterminedEvent.php:18
‪TYPO3\CMS\Core\TypoScript\IncludeTree\Event\AfterTemplatesHaveBeenDeterminedEvent\getSite
‪getSite()
Definition: AfterTemplatesHaveBeenDeterminedEvent.php:49