<?phpnamespace App\Entity;use App\Repository\JoursFermeturesRepository;use Doctrine\Common\Collections\ArrayCollection;use Doctrine\Common\Collections\Collection;use Doctrine\ORM\Mapping as ORM;/** * @ORM\Entity(repositoryClass=JoursFermeturesRepository::class) */class JoursFermetures{ /** * @ORM\Id * @ORM\GeneratedValue * @ORM\Column(type="integer") */ private $id; /** * @ORM\ManyToOne(targetEntity=Lieux::class, inversedBy="joursFermetures") */ private $Lieux; /** * @ORM\ManyToOne(targetEntity=Avocats::class, inversedBy="joursFermetures") */ private $Avocats; /** * @ORM\Column(type="date", nullable=true) */ private $Date; /** * @ORM\Column(type="integer", nullable=true) */ private $HeureOuverture; /** * @ORM\Column(type="integer", nullable=true) */ private $HeureFermeture; /** * @ORM\OneToMany(targetEntity=Tranches::class, mappedBy="JoursFermetures") */ private $tranches; public function __construct() { $this->tranches = new ArrayCollection(); } public function getId(): ?int { return $this->id; } public function getLieux(): ?Lieux { return $this->Lieux; } public function setLieux(?Lieux $Lieux): self { $this->Lieux = $Lieux; return $this; } public function getAvocats(): ?Avocats { return $this->Avocats; } public function setAvocats(?Avocats $Avocats): self { $this->Avocats = $Avocats; return $this; } public function getDate(): ?\DateTimeInterface { return $this->Date; } public function setDate(?\DateTimeInterface $Date): self { $this->Date = $Date; return $this; } public function getHeureOuverture(): ?int { return $this->HeureOuverture; } public function setHeureOuverture(?int $HeureOuverture): self { $this->HeureOuverture = $HeureOuverture; return $this; } public function getHeureFermeture(): ?int { return $this->HeureFermeture; } public function setHeureFermeture(?int $HeureFermeture): self { $this->HeureFermeture = $HeureFermeture; return $this; } /** * @return Collection<int, Tranches> */ public function getTranches(): Collection { return $this->tranches; } public function addTranch(Tranches $tranch): self { if (!$this->tranches->contains($tranch)) { $this->tranches[] = $tranch; $tranch->setJoursFermetures($this); } return $this; } public function removeTranch(Tranches $tranch): self { if ($this->tranches->removeElement($tranch)) { // set the owning side to null (unless already changed) if ($tranch->getJoursFermetures() === $this) { $tranch->setJoursFermetures(null); } } return $this; }}