‪TYPO3CMS  ‪main
AfterRecordLanguageOverlayEvent.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 
21 
26 {
27  public function ‪__construct(
28  private readonly string $table,
29  private readonly array ‪$record,
30  private array|null $localizedRecord,
31  private bool $overlayingWasAttempted,
32  private readonly ‪LanguageAspect $languageAspect
33  ) {}
34 
35  public function ‪getTable(): string
36  {
37  return $this->table;
38  }
39 
40  public function ‪getRecord(): array
41  {
42  return ‪$this->record;
43  }
44 
46  {
47  return $this->languageAspect;
48  }
49 
50  public function ‪setLocalizedRecord(array|null $localizedRecord): void
51  {
52  $this->‪overlayingWasAttempted = true;
53  $this->localizedRecord = $localizedRecord;
54  }
55 
56  public function ‪getLocalizedRecord(): array|null
57  {
58  return $this->localizedRecord;
59  }
60 
64  public function ‪overlayingWasAttempted(): bool
65  {
66  return $this->overlayingWasAttempted;
67  }
68 }
‪TYPO3\CMS\Core\Domain\Event
Definition: AfterRecordLanguageOverlayEvent.php:18
‪TYPO3\CMS\Core\Domain\Event\AfterRecordLanguageOverlayEvent
Definition: AfterRecordLanguageOverlayEvent.php:26
‪TYPO3\CMS\Core\Domain\Event\AfterRecordLanguageOverlayEvent\getLocalizedRecord
‪getLocalizedRecord()
Definition: AfterRecordLanguageOverlayEvent.php:56
‪TYPO3\CMS\Core\Domain\Event\AfterRecordLanguageOverlayEvent\setLocalizedRecord
‪setLocalizedRecord(array|null $localizedRecord)
Definition: AfterRecordLanguageOverlayEvent.php:50
‪TYPO3\CMS\Core\Domain\Event\AfterRecordLanguageOverlayEvent\__construct
‪__construct(private readonly string $table, private readonly array $record, private array|null $localizedRecord, private bool $overlayingWasAttempted, private readonly LanguageAspect $languageAspect)
Definition: AfterRecordLanguageOverlayEvent.php:27
‪TYPO3\CMS\Webhooks\Message\$record
‪identifier readonly int readonly array $record
Definition: PageModificationMessage.php:36
‪TYPO3\CMS\Core\Domain\Event\AfterRecordLanguageOverlayEvent\overlayingWasAttempted
‪overlayingWasAttempted()
Definition: AfterRecordLanguageOverlayEvent.php:64
‪TYPO3\CMS\Core\Context\LanguageAspect
Definition: LanguageAspect.php:57
‪TYPO3\CMS\Core\Domain\Event\AfterRecordLanguageOverlayEvent\getRecord
‪getRecord()
Definition: AfterRecordLanguageOverlayEvent.php:40
‪TYPO3\CMS\Core\Domain\Event\AfterRecordLanguageOverlayEvent\getTable
‪getTable()
Definition: AfterRecordLanguageOverlayEvent.php:35
‪TYPO3\CMS\Core\Domain\Event\AfterRecordLanguageOverlayEvent\getLanguageAspect
‪getLanguageAspect()
Definition: AfterRecordLanguageOverlayEvent.php:45