src/Entity/CritereSatisfaction.php line 11

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\CritereSatisfactionRepository;
  4. use Doctrine\Common\Collections\ArrayCollection;
  5. use Doctrine\Common\Collections\Collection;
  6. use Doctrine\ORM\Mapping as ORM;
  7. #[ORM\Entity(repositoryClassCritereSatisfactionRepository::class)]
  8. class CritereSatisfaction
  9. {
  10.     #[ORM\Id]
  11.     #[ORM\GeneratedValue]
  12.     #[ORM\Column]
  13.     private ?int $id null;
  14.     #[ORM\OneToMany(targetEntity:UserFicheSatisfactionReponse::class, mappedBy:"critereSatisfaction")]
  15.     private Collection $userFicheSatisfactionReponse;
  16.  
  17.     #[ORM\Column(length255)]
  18.     private ?string $label null;
  19.   public function __construct()
  20.   {
  21.     $this->userFicheSatisfactionReponse = new ArrayCollection();
  22.   }
  23.     public function getId(): ?int
  24.     {
  25.         return $this->id;
  26.     }
  27.     /**
  28.      * Get the value of label
  29.      */ 
  30.     public function getLabel()
  31.     {
  32.         return $this->label;
  33.     }
  34.     /**
  35.      * Set the value of label
  36.      *
  37.      * @return  self
  38.      */ 
  39.     public function setLabel($label)
  40.     {
  41.         $this->label $label;
  42.         return $this;
  43.     }
  44.     /**
  45.      * Get the value of userFicheSatisfactionReponse
  46.      */ 
  47.     public function getUserFicheSatisfactionReponse()
  48.     {
  49.         return $this->userFicheSatisfactionReponse;
  50.     }
  51.     /**
  52.      * Set the value of userFicheSatisfactionReponse
  53.      *
  54.      * @return  self
  55.      */ 
  56.     public function setUserFicheSatisfactionReponse($userFicheSatisfactionReponse)
  57.     {
  58.         $this->userFicheSatisfactionReponse $userFicheSatisfactionReponse;
  59.         return $this;
  60.     }
  61.     public function addUserFicheSatisfactionReponse(UserFicheSatisfactionReponse $userFicheSatisfactionReponse): self
  62.     {
  63.         if (!$this->userFicheSatisfactionReponse->contains($userFicheSatisfactionReponse)) {
  64.             $this->userFicheSatisfactionReponse->add($userFicheSatisfactionReponse);
  65.             $userFicheSatisfactionReponse->setCritereSatisfaction($this);
  66.         }
  67.         return $this;
  68.     }
  69.     public function removeUserFicheSatisfactionReponse(UserFicheSatisfactionReponse $userFicheSatisfactionReponse): self
  70.     {
  71.         if ($this->userFicheSatisfactionReponse->removeElement($userFicheSatisfactionReponse)) {
  72.             // set the owning side to null (unless already changed)
  73.             if ($userFicheSatisfactionReponse->getCritereSatisfaction() === $this) {
  74.                 $userFicheSatisfactionReponse->setCritereSatisfaction(null);
  75.             }
  76.         }
  77.         return $this;
  78.     }
  79. }