src/Entity/Etablissement.php line 13
<?php
namespace App\Entity;
use App\Repository\EtablissementRepository;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;
use Doctrine\ORM\Mapping as ORM;
use Doctrine\DBAL\Types\Types;
#[ORM\Entity(repositoryClass: EtablissementRepository::class)]
class Etablissement
{
#[ORM\Id]
#[ORM\GeneratedValue]
#[ORM\Column]
private ?int $id = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $nomCourt = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $nomLong = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $adresse = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $email = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $siteWeb = null;
#[ORM\Column(nullable: true)]
private ?int $telephone = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $fax = null;
#[ORM\Column(type: Types::TEXT, nullable: true)]
private ?string $description = null;
#[ORM\OneToMany(mappedBy: 'etablissement', targetEntity: Directeur::class)]
private Collection $directeurs;
#[ORM\OneToMany(mappedBy: 'etablissement', targetEntity: Chercheur::class)]
private Collection $chercheurs;
#[ORM\OneToMany(mappedBy: 'etablissement', targetEntity: StructureRecherche::class)]
private Collection $structureRecherches;
#[ORM\Column(length: 255, nullable: true)]
private ?string $nomArabe = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $logo = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $image1 = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $image2 = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $image3 = null;
public function __construct()
{
$this->directeurs = new ArrayCollection();
$this->chercheurs = new ArrayCollection();
$this->structureRecherches = new ArrayCollection();
}
public function getId(): ?int
{
return $this->id;
}
public function getNomCourt(): ?string
{
return $this->nomCourt;
}
public function setNomCourt(?string $nomCourt): self
{
$this->nomCourt = $nomCourt;
return $this;
}
public function getNomLong(): ?string
{
return $this->nomLong;
}
public function setNomLong(?string $nomLong): self
{
$this->nomLong = $nomLong;
return $this;
}
public function getAdresse(): ?string
{
return $this->adresse;
}
public function setAdresse(?string $adresse): self
{
$this->adresse = $adresse;
return $this;
}
public function getEmail(): ?string
{
return $this->email;
}
public function setEmail(?string $email): self
{
$this->email = $email;
return $this;
}
public function getSiteWeb(): ?string
{
return $this->siteWeb;
}
public function setSiteWeb(?string $siteWeb): self
{
$this->siteWeb = $siteWeb;
return $this;
}
public function getTelephone(): ?int
{
return $this->telephone;
}
public function setTelephone(?int $telephone): self
{
$this->telephone = $telephone;
return $this;
}
public function getFax(): ?string
{
return $this->fax;
}
public function setFax(?string $fax): self
{
$this->fax = $fax;
return $this;
}
public function getDescription(): ?string
{
return $this->description;
}
public function setDescription(?string $description): self
{
$this->description = $description;
return $this;
}
/**
* @return Collection<int, Directeur>
*/
public function getDirecteurs(): Collection
{
return $this->directeurs;
}
public function addDirecteur(Directeur $directeur): self
{
if (!$this->directeurs->contains($directeur)) {
$this->directeurs->add($directeur);
$directeur->setEtablissement($this);
}
return $this;
}
public function removeDirecteur(Directeur $directeur): self
{
if ($this->directeurs->removeElement($directeur)) {
// set the owning side to null (unless already changed)
if ($directeur->getEtablissement() === $this) {
$directeur->setEtablissement(null);
}
}
return $this;
}
/**
* @return Collection<int, Chercheur>
*/
public function getChercheurs(): Collection
{
return $this->chercheurs;
}
public function addChercheur(Chercheur $chercheur): self
{
if (!$this->chercheurs->contains($chercheur)) {
$this->chercheurs->add($chercheur);
$chercheur->setEtablissement($this);
}
return $this;
}
public function removeChercheur(Chercheur $chercheur): self
{
if ($this->chercheurs->removeElement($chercheur)) {
// set the owning side to null (unless already changed)
if ($chercheur->getEtablissement() === $this) {
$chercheur->setEtablissement(null);
}
}
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->setEtablissement($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->getEtablissement() === $this) {
$structureRecherch->setEtablissement(null);
}
}
return $this;
}
public function getNomArabe(): ?string
{
return $this->nomArabe;
}
public function setNomArabe(?string $nomArabe): self
{
$this->nomArabe = $nomArabe;
return $this;
}
public function __toString(): string
{
return $this->nomLong;
}
public function getLogo(): ?string
{
return $this->logo;
}
public function setLogo(?string $logo): self
{
$this->logo = $logo;
return $this;
}
public function getImage1(): ?string
{
return $this->image1;
}
public function setImage1(?string $image1): self
{
$this->image1 = $image1;
return $this;
}
public function getImage2(): ?string
{
return $this->image2;
}
public function setImage2(?string $image2): self
{
$this->image2 = $image2;
return $this;
}
public function getImage3(): ?string
{
return $this->image3;
}
public function setImage3(?string $image3): self
{
$this->image3 = $image3;
return $this;
}
}