src/Entity/Role.php line 9

  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\RoleRepository;
  4. use Doctrine\ORM\Mapping as ORM;
  5. #[ORM\Entity(repositoryClassRoleRepository::class)]
  6. class Role
  7. {
  8.     #[ORM\Id]
  9.     #[ORM\GeneratedValue]
  10.     #[ORM\Column]
  11.     private ?int $id null;
  12.     #[ORM\Columnlength100)]
  13.     private ?string $roleName null;
  14.     #[ORM\Column(length100)]
  15.     private ?string $libelle null;
  16.     public function getId(): ?int
  17.     {
  18.         return $this->id;
  19.     }
  20.     public function getRoleName(): ?string
  21.     {
  22.         return $this->roleName;
  23.     }
  24.     public function setRoleName(string $roleName): self
  25.     {
  26.         $this->roleName $roleName;
  27.         return $this;
  28.     }
  29.     public function getLibelle(): ?string
  30.     {
  31.         return $this->libelle;
  32.     }
  33.     public function setLibelle(string $libelle): self
  34.     {
  35.         $this->libelle $libelle;
  36.         return $this;
  37.     }
  38.     public function __toString(): string
  39.     {
  40.         return (string) $this->libelle;
  41.     }
  42. }