<?php
namespace App\Entity;
use App\Repository\LogicielsFormationsRepository;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;
use Doctrine\ORM\Mapping as ORM;
/**
* @ORM\Entity(repositoryClass=LogicielsFormationsRepository::class)
*/
class LogicielsFormations
{
/**
* @ORM\Id
* @ORM\GeneratedValue
* @ORM\Column(type="integer")
*/
private $id;
/**
* @ORM\Column(type="string", length=255, nullable=true)
*/
private $TitreFr;
/**
* @ORM\Column(type="string", length=255, nullable=true)
*/
private $TitreEn;
/**
* @ORM\OneToMany(targetEntity=Formations::class, mappedBy="LogicielsFormations")
*/
private $formations;
public function __construct()
{
$this->formations = new ArrayCollection();
}
public function __toString()
{
return $this->TitreFr;
}
public function getId(): ?int
{
return $this->id;
}
public function getTitreFr(): ?string
{
return $this->TitreFr;
}
public function setTitreFr(?string $TitreFr): self
{
$this->TitreFr = $TitreFr;
return $this;
}
public function getTitreEn(): ?string
{
return $this->TitreEn;
}
public function setTitreEn(?string $TitreEn): self
{
$this->TitreEn = $TitreEn;
return $this;
}
/**
* @return Collection<int, Formations>
*/
public function getFormations(): Collection
{
return $this->formations;
}
public function addFormation(Formations $formation): self
{
if (!$this->formations->contains($formation)) {
$this->formations[] = $formation;
$formation->setLogicielsFormations($this);
}
return $this;
}
public function removeFormation(Formations $formation): self
{
if ($this->formations->removeElement($formation)) {
// set the owning side to null (unless already changed)
if ($formation->getLogicielsFormations() === $this) {
$formation->setLogicielsFormations(null);
}
}
return $this;
}
}