Exponential 5.x Kernel 7.5.40 Exponential New Stack (Symfony-based) Kernel — PHP Class Reference

Repository/Slot/User/DeleteUser.php
Go to the documentation of this file.
1 <?php
2
7 namespace eZ\Publish\Core\Repository\Slot\User;
8
9 use eZ\Bundle\EzPublishCoreBundle\EventListener\User\eZ;
10 use eZ\Publish\API\Repository\ContentTypeService;
11 use eZ\Publish\Core\SignalSlot\Signal;
12 use eZ\Publish\Core\SignalSlot\Slot;
13
14 class DeleteUser extends Slot
15 {
17 private $contentTypeService;
18
19 public function __construct(ContentTypeService $contentTypeService)
20 {
21 $this->contentTypeService = $contentTypeService;
22 }
23
24 public function receive(Signal $signal)
25 {
26 if (!$signal instanceof Signal\UserService\DeleteUserSignal) {
27 return;
28 }
29
30 $this->contentTypeService->deleteUserDrafts($signal->userId);
31 }
32 }
eZ\Publish\Core\Repository\Slot\User\DeleteUser
Definition: Repository/Slot/User/DeleteUser.php:15
eZ\Publish\Core\Repository\Slot\User\DeleteUser\receive
receive(Signal $signal)
Receive the given $signal and react on it.
Definition: Repository/Slot/User/DeleteUser.php:24
eZ\Publish\Core\Repository\Slot\User\DeleteUser\__construct
__construct(ContentTypeService $contentTypeService)
Definition: Repository/Slot/User/DeleteUser.php:19
eZ\Publish\Core\Repository\Slot\User\DeleteUser\$contentTypeService
$contentTypeService
Definition: Repository/Slot/User/DeleteUser.php:17
eZ\Publish\Core\Repository\UserService
Definition: Core/Repository/UserService.php:61
eZ\Publish\Core\SignalSlot\Signal
Base class for Signals.
Definition: Signal.php:18
eZ\Publish\Core\SignalSlot\Slot
A Slot can be assigned to receive a certain Signal.
Definition: SignalSlot/Slot.php:13
eZ\Publish\API\Repository\ContentTypeService
Definition: API/Repository/ContentTypeService.php:25
eZ\Publish\Core\Repository\Slot\User
Definition: Repository/Slot/User/DeleteUser.php:7
Copyright © 1998 – 2026 7x. All rights reserved. Licensed under the GNU GPLv2+.