class AuditPreEntityDeleteEvent in Acquia Content Hub 8
Event fired before deleting an entity.
Class AuditPreEntityDeleteEvent.
Hierarchy
- class \Drupal\acquia_contenthub_audit\Event\AuditPreEntityDeleteEvent extends \Symfony\Component\EventDispatcher\Event
Expanded class hierarchy of AuditPreEntityDeleteEvent
2 files declare their use of AuditPreEntityDeleteEvent
- ContentLockPreEntityDelete.php in acquia_contenthub_audit/
src/ EventSubscriber/ ContentLockPreEntityDelete.php - SubscriberAudit.php in acquia_contenthub_audit/
src/ SubscriberAudit.php
File
- acquia_contenthub_audit/
src/ Event/ AuditPreEntityDeleteEvent.php, line 13
Namespace
Drupal\acquia_contenthub_audit\EventView source
class AuditPreEntityDeleteEvent extends Event {
/**
* The entity about to be deleted.
*
* @var \Drupal\Core\Entity\ContentEntityInterface
*/
protected $entity;
/**
* AuditPreEntityDeleteEvent constructor.
*
* @param \Drupal\Core\Entity\ContentEntityInterface $entity
* The entity that is about to be deleted.
*/
public function __construct(ContentEntityInterface $entity) {
$this->entity = $entity;
}
/**
* The entity to be deleted.
*
* @return \Drupal\Core\Entity\ContentEntityInterface
* Entity.
*/
public function getEntity() {
return $this->entity;
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
AuditPreEntityDeleteEvent:: |
protected | property | The entity about to be deleted. | |
AuditPreEntityDeleteEvent:: |
public | function | The entity to be deleted. | |
AuditPreEntityDeleteEvent:: |
public | function | AuditPreEntityDeleteEvent constructor. |