src/Entity/Seance.php line 12

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\SeanceRepository;
  4. use Doctrine\Common\Collections\ArrayCollection;
  5. use Doctrine\Common\Collections\Collection;
  6. use Doctrine\DBAL\Types\Types;
  7. use Doctrine\ORM\Mapping as ORM;
  8. #[ORM\Entity(repositoryClassSeanceRepository::class)]
  9. class Seance
  10. {
  11.     #[ORM\Id]
  12.     #[ORM\GeneratedValue]
  13.     #[ORM\Column]
  14.     private ?int $id null;
  15.     #[ORM\Column(length255)]
  16.     private ?string $titre null;
  17.     #[ORM\Column(typeTypes::SMALLINTnullabletrue)]
  18.     private ?int $duree null;
  19.     #[ORM\Column(typeTypes::TEXTnullabletrue)]
  20.     private ?string $objectifIntermediaire null;
  21.     #[ORM\Column(typeTypes::TEXTnullabletrue)]
  22.     private ?string $prerequis null;
  23.     #[ORM\Column(typeTypes::TEXTnullabletrue)]
  24.     private ?string $deroule null;
  25.     #[ORM\Column(typeTypes::TEXTnullabletrue)]
  26.     private ?string $ressourcesFournies null;
  27.     #[ORM\Column(typeTypes::TEXTnullabletrue)]
  28.     private ?string $remarque null;
  29.     #[ORM\ManyToOne(inversedBy'refSeances')]
  30.     #[ORM\JoinColumn(nullablefalse)]
  31.     private ?Sequence $refSequence null;
  32.     #[ORM\ManyToMany(targetEntityCompetence::class)]
  33.     private Collection $refCompetences;
  34.     #[ORM\ManyToMany(targetEntitySavoirTechnologique::class)]
  35.     private Collection $refSavoirTechnologique;
  36.     #[ORM\OneToMany(mappedBy'refSeance'targetEntitySeanceDetail::class, orphanRemovaltrue)]
  37.     #[ORM\OrderBy(["phase" => "ASC"])]
  38.     private Collection $refSeancesDetails;
  39.     #[ORM\Column(typeTypes::TEXTnullabletrue)]
  40.     private ?string $organisation null;
  41.     #[ORM\ManyToOne(inversedBy'refSeances')]
  42.     private ?ThemeSeance $refThemeSeance null;
  43.     #[ORM\Column(length255nullabletrue)]
  44.     private ?string $etape null;
  45.     #[ORM\Column(nullabletrue)]
  46.     private ?int $bloom null;
  47.     public function __construct()
  48.     {
  49.         $this->refCompetences = new ArrayCollection();
  50.         $this->refSavoirTechnologique = new ArrayCollection();
  51.         $this->refSeancesDetails = new ArrayCollection();
  52.     }
  53.     public function getId(): ?int
  54.     {
  55.         return $this->id;
  56.     }
  57.     public function getTitre(): ?string
  58.     {
  59.         return $this->titre;
  60.     }
  61.     public function setTitre(string $titre): self
  62.     {
  63.         $this->titre $titre;
  64.         return $this;
  65.     }
  66.     public function getDuree(): ?int
  67.     {
  68.         return $this->duree;
  69.     }
  70.     public function setDuree(?int $duree): self
  71.     {
  72.         $this->duree $duree;
  73.         return $this;
  74.     }
  75.     public function getObjectifIntermediaire(): ?string
  76.     {
  77.         return $this->objectifIntermediaire;
  78.     }
  79.     public function setObjectifIntermediaire(?string $objectifIntermediaire): self
  80.     {
  81.         $this->objectifIntermediaire $objectifIntermediaire;
  82.         return $this;
  83.     }
  84.     public function getPrerequis(): ?string
  85.     {
  86.         return $this->prerequis;
  87.     }
  88.     public function setPrerequis(?string $prerequis): self
  89.     {
  90.         $this->prerequis $prerequis;
  91.         return $this;
  92.     }
  93.     public function getDeroule(): ?string
  94.     {
  95.         return $this->deroule;
  96.     }
  97.     public function setDeroule(?string $deroule): self
  98.     {
  99.         $this->deroule $deroule;
  100.         return $this;
  101.     }
  102.     public function getRessourcesFournies(): ?string
  103.     {
  104.         return $this->ressourcesFournies;
  105.     }
  106.     public function setRessourcesFournies(?string $ressourcesFournies): self
  107.     {
  108.         $this->ressourcesFournies $ressourcesFournies;
  109.         return $this;
  110.     }
  111.     public function getRemarque(): ?string
  112.     {
  113.         return $this->remarque;
  114.     }
  115.     public function setRemarque(?string $remarque): self
  116.     {
  117.         $this->remarque $remarque;
  118.         return $this;
  119.     }
  120.     public function getRefSequence(): ?Sequence
  121.     {
  122.         return $this->refSequence;
  123.     }
  124.     public function setRefSequence(?Sequence $refSequence): self
  125.     {
  126.         $this->refSequence $refSequence;
  127.         return $this;
  128.     }
  129.     /**
  130.      * @return Collection<int, Competence>
  131.      */
  132.     public function getRefCompetences(): Collection
  133.     {
  134.         return $this->refCompetences;
  135.     }
  136.     public function addRefCompetence(Competence $refCompetence): self
  137.     {
  138.         if (!$this->refCompetences->contains($refCompetence)) {
  139.             $this->refCompetences->add($refCompetence);
  140.         }
  141.         return $this;
  142.     }
  143.     public function removeRefCompetence(Competence $refCompetence): self
  144.     {
  145.         $this->refCompetences->removeElement($refCompetence);
  146.         return $this;
  147.     }
  148.     /**
  149.      * @return Collection<int, SavoirTechnologique>
  150.      */
  151.     public function getRefSavoirTechnologique(): Collection
  152.     {
  153.         return $this->refSavoirTechnologique;
  154.     }
  155.     public function addRefSavoirTechnologique(SavoirTechnologique $refSavoirTechnologique): self
  156.     {
  157.         if (!$this->refSavoirTechnologique->contains($refSavoirTechnologique)) {
  158.             $this->refSavoirTechnologique->add($refSavoirTechnologique);
  159.         }
  160.         return $this;
  161.     }
  162.     public function removeRefSavoirTechnologique(SavoirTechnologique $refSavoirTechnologique): self
  163.     {
  164.         $this->refSavoirTechnologique->removeElement($refSavoirTechnologique);
  165.         return $this;
  166.     }
  167.     public function __toString(): string
  168.     {
  169.         return $this->getTitre();
  170.         // TODO: Implement __toString() method.
  171.     }
  172.     /**
  173.      * @return Collection<int, SeanceDetail>
  174.      */
  175.     public function getRefSeancesDetails(): Collection
  176.     {
  177.         return $this->refSeancesDetails;
  178.     }
  179.     public function addRefSeancesDetail(SeanceDetail $refSeancesDetail): self
  180.     {
  181.         if (!$this->refSeancesDetails->contains($refSeancesDetail)) {
  182.             $this->refSeancesDetails->add($refSeancesDetail);
  183.             $refSeancesDetail->setRefSeance($this);
  184.         }
  185.         return $this;
  186.     }
  187.     public function removeRefSeancesDetail(SeanceDetail $refSeancesDetail): self
  188.     {
  189.         if ($this->refSeancesDetails->removeElement($refSeancesDetail)) {
  190.             // set the owning side to null (unless already changed)
  191.             if ($refSeancesDetail->getRefSeance() === $this) {
  192.                 $refSeancesDetail->setRefSeance(null);
  193.             }
  194.         }
  195.         return $this;
  196.     }
  197.     public function getPositionSeance() :?int {
  198.         return $this->getRefSequence()->getRefSeances()->indexOf($this)+1;
  199.     }
  200.     public function getOrganisation(): ?string
  201.     {
  202.         return $this->organisation;
  203.     }
  204.     public function setOrganisation(?string $organisation): self
  205.     {
  206.         $this->organisation $organisation;
  207.         return $this;
  208.     }
  209.     public function getRefThemeSeance(): ?ThemeSeance
  210.     {
  211.         return $this->refThemeSeance;
  212.     }
  213.     public function setRefThemeSeance(?ThemeSeance $refThemeSeance): self
  214.     {
  215.         $this->refThemeSeance $refThemeSeance;
  216.         return $this;
  217.     }
  218.     public function getEtape(): ?string
  219.     {
  220.         return $this->etape;
  221.     }
  222.     public function setEtape(?string $etape): self
  223.     {
  224.         $this->etape $etape;
  225.         return $this;
  226.     }
  227.     public function getBloom(): ?int
  228.     {
  229.         return $this->bloom;
  230.     }
  231.     public function setBloom(?int $bloom): self
  232.     {
  233.         $this->bloom $bloom;
  234.         return $this;
  235.     }
  236. }