Files
domain-watchdog/src/Entity/DomainEvent.php

28 lines
626 B
PHP
Raw Normal View History

2024-07-10 23:30:59 +02:00
<?php
namespace App\Entity;
2024-07-11 17:01:16 +02:00
use App\Repository\DomainEventRepository;
2024-07-10 23:30:59 +02:00
use Doctrine\ORM\Mapping as ORM;
2024-07-11 17:01:16 +02:00
#[ORM\Entity(repositoryClass: DomainEventRepository::class)]
2024-07-11 22:20:20 +02:00
class DomainEvent extends Event
2024-07-10 23:30:59 +02:00
{
2024-07-12 01:49:46 +02:00
#[ORM\Id]
#[ORM\ManyToOne(targetEntity: Domain::class, cascade: ['persist'], inversedBy: 'events')]
2024-07-11 17:01:16 +02:00
#[ORM\JoinColumn(referencedColumnName: 'handle', nullable: false)]
2024-07-10 23:30:59 +02:00
private ?Domain $domain = null;
public function getDomain(): ?Domain
{
return $this->domain;
}
public function setDomain(?Domain $domain): static
{
$this->domain = $domain;
return $this;
}
}