src/Entity/DomaineScientifique.php line 11
<?php
namespace App\Entity;
use App\Repository\DomaineScientifiqueRepository;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;
use Doctrine\ORM\Mapping as ORM;
#[ORM\Entity(repositoryClass: DomaineScientifiqueRepository::class)]
class DomaineScientifique
{
#[ORM\Id]
#[ORM\GeneratedValue]
#[ORM\Column]
private ?int $id = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $nomAr = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $nomFr = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $nomAng = null;
#[ORM\OneToMany(mappedBy: 'domaine', targetEntity: StructureRecherche::class)]
private Collection $structureRecherches;
public function __construct()
{
$this->structureRecherches = new ArrayCollection();
}
public function getId(): ?int
{
return $this->id;
}
public function getNomAr(): ?string
{
return $this->nomAr;
}
public function setNomAr(?string $nomAr): self
{
$this->nomAr = $nomAr;
return $this;
}
public function getNomFr(): ?string
{
return $this->nomFr;
}
public function setNomFr(?string $nomFr): self
{
$this->nomFr = $nomFr;
return $this;
}
public function getNomAng(): ?string
{
return $this->nomAng;
}
public function setNomAng(?string $nomAng): self
{
$this->nomAng = $nomAng;
return $this;
}
/**
* @return Collection<int, StructureRecherche>
*/
public function getStructureRecherches(): Collection
{
return $this->structureRecherches;
}
public function addStructureRecherch(StructureRecherche $structureRecherch): self
{
if (!$this->structureRecherches->contains($structureRecherch)) {
$this->structureRecherches->add($structureRecherch);
$structureRecherch->setDomaine($this);
}
return $this;
}
public function removeStructureRecherch(StructureRecherche $structureRecherch): self
{
if ($this->structureRecherches->removeElement($structureRecherch)) {
// set the owning side to null (unless already changed)
if ($structureRecherch->getDomaine() === $this) {
$structureRecherch->setDomaine(null);
}
}
return $this;
}
}