src/Entity/Categorie.php line 11
<?phpnamespace App\Entity;use App\Repository\CategorieRepository;use Doctrine\Common\Collections\ArrayCollection;use Doctrine\Common\Collections\Collection;use Doctrine\ORM\Mapping as ORM;#[ORM\Entity(repositoryClass: CategorieRepository::class)]class Categorie{#[ORM\Id]#[ORM\GeneratedValue]#[ORM\Column]private ?int $id = null;#[ORM\Column(length: 255)]private ?string $titre = null;#[ORM\ManyToMany(targetEntity: Projet::class, mappedBy: 'tag', cascade: ['persist'])]private Collection $tags;#[ORM\Column(length: 2550)]private ?string $description = null;public function __construct(){$this->tags = new ArrayCollection();}public function getId(): ?int{return $this->id;}public function getTitre(): ?string{return $this->titre;}public function setTitre(string $titre): self{$this->titre = $titre;return $this;}/*** @return Collection<int, Projet>*/public function getTags(): Collection{return $this->tags;}public function addTag(Projet $tag): self{if (!$this->tags->contains($tag)) {$this->tags->add($tag);}return $this;}public function removeTag(Projet $tag): self{$this->tags->removeElement($tag);return $this;}public function __toString(){return $this->titre;}public function getDescription(): ?string{return $this->description;}public function setDescription(string $description): self{$this->description = $description;return $this;}}