<?phpnamespace App\Entity;use App\Repository\RendezVousRecurrenceRepository;use Doctrine\Common\Collections\ArrayCollection;use Doctrine\Common\Collections\Collection;use Doctrine\ORM\Mapping as ORM;/** * @ORM\Entity(repositoryClass=RendezVousRecurrenceRepository::class) */class RendezVousRecurrence{ /** * @ORM\Id * @ORM\GeneratedValue * @ORM\Column(type="integer") */ private $id; /** * @ORM\OneToMany(targetEntity=Rendezvous::class, mappedBy="rendezVousRecurrence") */ private $recurrence; /** * @ORM\OneToMany(targetEntity=Rendezvous::class, mappedBy="recurrence") */ private $rendezVouses; /** * @ORM\Column(type="integer", nullable=true) */ private $id_old; public function __construct() { $this->recurrence = new ArrayCollection(); $this->rendezVouses = new ArrayCollection(); } public function getId(): ?int { return $this->id; } /** * @return Collection<int, Rendezvous> */ public function getRendezVouses(): Collection { return $this->rendezVouses; } public function addRendezVouse(Rendezvous $rendezVouse): self { if (!$this->rendezVouses->contains($rendezVouse)) { $this->rendezVouses[] = $rendezVouse; $rendezVouse->setRecurrence($this); } return $this; } public function removeRendezVouse(Rendezvous $rendezVouse): self { if ($this->rendezVouses->removeElement($rendezVouse)) { // set the owning side to null (unless already changed) if ($rendezVouse->getRecurrence() === $this) { $rendezVouse->setRecurrence(null); } } return $this; } public function getIdOld(): ?int { return $this->id_old; } public function setIdOld(int $id_old): self { $this->id_old = $id_old; return $this; } /** * @return Collection<int, Rendezvous> */ public function getRecurrence(): Collection { return $this->recurrence; } public function addRecurrence(Rendezvous $recurrence): self { if (!$this->recurrence->contains($recurrence)) { $this->recurrence->add($recurrence); $recurrence->setRecurrence($this); } return $this; } public function removeRecurrence(Rendezvous $recurrence): self { if ($this->recurrence->removeElement($recurrence)) { // set the owning side to null (unless already changed) if ($recurrence->getRecurrence() === $this) { $recurrence->setRecurrence(null); } } return $this; }}