src/Entity/SchoolYear.php line 17

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\SchoolYearRepository;
  4. use Doctrine\Common\Collections\ArrayCollection;
  5. use Doctrine\Common\Collections\Collection;
  6. use Doctrine\ORM\Mapping as ORM;
  7. use Doctrine\ORM\Mapping\HasLifecycleCallbacks;
  8. use Symfony\Bridge\Doctrine\Validator\Constraints\UniqueEntity;
  9. use App\Entity\Traits\Timestampable;
  10. use JMS\Serializer\Annotation\Groups;
  11. #[ORM\HasLifecycleCallbacks]
  12. #[ORM\Entity(repositoryClassSchoolYearRepository::class)]
  13. #[UniqueEntity(fields: ['name'], message'cette année existe deja')]
  14. class SchoolYear
  15. {
  16.     use Timestampable;
  17.     #[ORM\Id]
  18.     #[ORM\GeneratedValue]
  19.     #[ORM\Column]
  20.     #[Groups(['note','getBulletin','getExamStudent','getLate','getAbsence','getPunish''getStatsStudentParentIndex''getDoc''getPunish''getNews','getNewsSearch''homework''getEvent''getAgenda',  ])]
  21.     private ?int $id null;
  22.     #[ORM\Column(length255)]
  23.     #[Groups(['note','getBulletin','getExamStudent','getLate','getAbsence','getPunish''getStatsStudentParentIndex''getDoc''getPunish''getNews','getNewsSearch''homework''getEvent''getAgenda',  ])]
  24.     private ?string $name null;
  25.     #[ORM\Column]
  26.     #[Groups(['note','getBulletin','getExamStudent','getLate','getAbsence','getPunish''getStatsStudentParentIndex''getDoc''getPunish''getNews','getNewsSearch''homework''getEvent''getAgenda',  ])]
  27.     private ?bool $active null;
  28.     #[ORM\OneToMany(mappedBy'year'targetEntityUserYear::class)]
  29.     private Collection $userYears;
  30.     #[ORM\OneToMany(mappedBy'year'targetEntityStudentYear::class)]
  31.     private Collection $studentYears;
  32.     #[ORM\OneToMany(mappedBy'year'targetEntityHomeWork::class)]
  33.     private Collection $homeWorks;
  34.     #[ORM\OneToMany(mappedBy'year'targetEntityHomeWorkYear::class)]
  35.     private Collection $homeWorkYears;
  36.     #[ORM\OneToMany(mappedBy'year'targetEntityLate::class)]
  37.     private Collection $lates;
  38.     #[ORM\OneToMany(mappedBy'year'targetEntityChat::class)]
  39.     private Collection $chats;
  40.     #[ORM\OneToMany(mappedBy'year'targetEntityAbsence::class)]
  41.     private Collection $absences;
  42.     #[ORM\OneToMany(mappedBy'year'targetEntityNote::class)]
  43.     private Collection $notes;
  44.     #[ORM\OneToMany(mappedBy'year'targetEntityExams::class)]
  45.     private Collection $exams;
  46.     #[ORM\OneToMany(mappedBy'year'targetEntityDocInfo::class)]
  47.     private Collection $docInfos;
  48.     #[ORM\ManyToOne(inversedBy'schoolYears'cascade: ["persist"])]
  49.     private ?User $author null;
  50.     #[ORM\ManyToOne(inversedBy'schoolYearsEdited'cascade: ["persist"])]
  51.     private ?User $editor null;
  52.     #[ORM\OneToMany(mappedBy'year'targetEntityPunish::class)]
  53.     private Collection $punishes;
  54.     #[ORM\OneToMany(mappedBy'year'targetEntityDiscussion::class)]
  55.     private Collection $discussions;
  56.     #[ORM\OneToMany(mappedBy'year'targetEntityDiscussionClass::class)]
  57.     private Collection $discussionClasses;
  58.     #[ORM\OneToMany(mappedBy'year'targetEntityAgenda::class)]
  59.     private Collection $agendas;
  60.     #[ORM\OneToMany(mappedBy'year'targetEntityExamAgenda::class)]
  61.     private Collection $examAgendas;
  62.     #[ORM\OneToMany(mappedBy'year'targetEntityQuarter::class, orphanRemovaltrue)]
  63.     private Collection $quarters;
  64.     #[ORM\OneToMany(mappedBy'year'targetEntityGlobalQuarter::class)]
  65.     private Collection $globalQuarters;
  66.     #[ORM\OneToMany(mappedBy'year'targetEntityAppreciation::class, orphanRemovaltrue)]
  67.     private Collection $appreciations;
  68.     #[ORM\OneToMany(mappedBy'year'targetEntityLocalAccount::class)]
  69.     private Collection $localAccounts;
  70.     #[ORM\OneToMany(mappedBy'year'targetEntityDisciplineWarning::class)]
  71.     private Collection $disciplineWarnings;
  72.     #[ORM\OneToMany(mappedBy'year'targetEntityDisciplineBlame::class)]
  73.     private Collection $disciplineBlames;
  74.     #[ORM\OneToMany(mappedBy'year'targetEntityDisciplineExclusion::class)]
  75.     private Collection $disciplineExclusions;
  76.     #[ORM\OneToMany(mappedBy'year'targetEntityParentNote::class)]
  77.     private Collection $parentNotes;
  78.     #[ORM\OneToMany(mappedBy'year'targetEntityJustifyAbsence::class)]
  79.     private Collection $justifyAbsences;
  80.     #[ORM\OneToMany(mappedBy'year'targetEntitySubject::class)]
  81.     private Collection $subjects;
  82.     /**
  83.      * Versions du programme national (SubjectReference) associées à
  84.      * cette année scolaire. Permet de faire évoluer le programme
  85.      * d'une année à l'autre sans perdre l'historique.
  86.      */
  87.     #[ORM\OneToMany(mappedBy'year'targetEntitySubjectReference::class)]
  88.     private Collection $subjectReferences;
  89.     #[ORM\OneToMany(mappedBy'year'targetEntityAbsenceRetainedConfig::class)]
  90.     private Collection $absenceRetainedConfigs;
  91.     #[ORM\OneToMany(mappedBy'year'targetEntityAbsenceWarningConfig::class)]
  92.     private Collection $absenceWarningConfigs;
  93.     #[ORM\OneToMany(mappedBy'year'targetEntityAbsenceExclusionConfig::class)]
  94.     private Collection $absenceExclusionConfigs;
  95.     #[ORM\OneToMany(mappedBy'year'targetEntityAbsenceBlameConfig::class)]
  96.     private Collection $absenceBlameConfigs;
  97.     #[ORM\OneToMany(mappedBy'year'targetEntityDisciplineRetained::class)]
  98.     private Collection $disciplineRetaineds;
  99.     #[ORM\OneToMany(mappedBy'year'targetEntityDefinitiveExclusion::class)]
  100.     private Collection $definitiveExclusions;
  101.     #[ORM\OneToMany(mappedBy'year'targetEntityDisciplineConcile::class)]
  102.     private Collection $disciplineConciles;
  103.     #[ORM\OneToMany(mappedBy'year'targetEntityAbsenceDisciplineConcileConfig::class)]
  104.     private Collection $absenceDisciplineConcileConfigs;
  105.     #[ORM\OneToMany(mappedBy'year'targetEntityWarningBlameConfig::class)]
  106.     private Collection $warningBlameConfigs;
  107.     #[ORM\OneToMany(mappedBy'year'targetEntityWarningDefinitiveExlusionConfig::class)]
  108.     private Collection $warningDefinitiveExlusionConfigs;
  109.     #[ORM\OneToMany(mappedBy'year'targetEntityPrimaryParentNote::class)]
  110.     private Collection $primaryParentNotes;
  111.     #[ORM\OneToMany(mappedBy'year'targetEntityPrimaryNote::class)]
  112.     private Collection $primaryNotes;
  113.     #[ORM\OneToMany(mappedBy'year'targetEntityVerbalProcessCategory::class)]
  114.     private Collection $verbalProcessCategories;
  115.     #[ORM\OneToMany(mappedBy'year'targetEntityGlobalDisciplineConfig::class)]
  116.     private Collection $globalDisciplineConfigs;
  117.     #[ORM\OneToMany(mappedBy'year'targetEntityDisciplinePunish::class)]
  118.     private Collection $disciplinePunishes;
  119.     #[ORM\OneToMany(mappedBy'year'targetEntityGlobalDisciplineEnabledConfig::class)]
  120.     private Collection $globalDisciplineEnabledConfigs;
  121.     #[ORM\OneToMany(mappedBy'year'targetEntityBlamePunishConfig::class)]
  122.     private Collection $blamePunishConfigs;
  123.     #[ORM\OneToMany(mappedBy'year'targetEntityAbsencePunishConfig::class)]
  124.     private Collection $absencePunishConfigs;
  125.     #[ORM\OneToMany(mappedBy'year'targetEntityWarningPunishConfig::class)]
  126.     private Collection $warningPunishConfigs;
  127.     #[ORM\OneToMany(mappedBy'year'targetEntityPunishRetainedConfig::class)]
  128.     private Collection $punishRetainedConfigs;
  129.     #[ORM\OneToMany(mappedBy'year'targetEntityPunishWarningConfig::class)]
  130.     private Collection $punishWarningConfigs;
  131.     #[ORM\OneToMany(mappedBy'year'targetEntityPunishBlameConfig::class)]
  132.     private Collection $punishBlameConfigs;
  133.     #[ORM\OneToMany(mappedBy'year'targetEntityPunishExclusionConfig::class)]
  134.     private Collection $punishExclusionConfigs;
  135.     #[ORM\Column(length255)]
  136.     #[Groups(['note','getBulletin','getExamStudent','getLate','getAbsence','getPunish''getStatsStudentParentIndex'])]
  137.     private ?string $nameEn null;
  138.     #[ORM\OneToMany(mappedBy'year'targetEntitySchoolYearInfos::class)]
  139.     private Collection $schoolYearInfos;
  140.     #[ORM\OneToMany(mappedBy'year'targetEntityBlame::class)]
  141.     private Collection $blames;
  142.     #[ORM\OneToMany(mappedBy'year'targetEntityWarning::class)]
  143.     private Collection $warnings;
  144.     #[ORM\OneToMany(mappedBy'year'targetEntityRetained::class)]
  145.     private Collection $retaineds;
  146.     #[ORM\OneToMany(mappedBy'year'targetEntityHonnorTableLimitMoy::class)]
  147.     private Collection $honnorTableLimitMoys;
  148.     #[ORM\OneToMany(mappedBy'year'targetEntityNews::class)]
  149.     private Collection $news;
  150.     #[ORM\OneToMany(mappedBy'year'targetEntityEvent::class)]
  151.     private Collection $events;
  152.     #[ORM\OneToMany(mappedBy'year'targetEntityAdmissionLimit::class)]
  153.     private Collection $admissionLimits;
  154.     #[ORM\OneToOne(mappedBy'year'cascade: ['persist'])]
  155.     private ?AgendaTimeConvertion $agendaTimeConvertion null;
  156.     #[ORM\OneToMany(mappedBy'year'targetEntityExamWeek::class)]
  157.     private Collection $examWeeks;
  158.     #[ORM\OneToMany(mappedBy'year'targetEntityCompetence::class)]
  159.     private Collection $competences;
  160.     #[ORM\OneToMany(mappedBy'year'targetEntityWeekSubjectGoal::class)]
  161.     private Collection $weekSubjectGoals;
  162.     #[ORM\OneToMany(mappedBy'year'targetEntityProfSchoolPlanner::class)]
  163.     private Collection $profSchoolPlanners;
  164.     #[ORM\OneToMany(mappedBy'year'targetEntityProfTime::class)]
  165.     private Collection $profTimes;
  166.     #[ORM\OneToMany(mappedBy'year'targetEntitySchoolPlannerType::class)]
  167.     private Collection $schoolPlannerTypes;
  168.     #[ORM\OneToMany(mappedBy'year'targetEntityAgendaElement::class)]
  169.     private Collection $agendaElements;
  170.     #[ORM\OneToMany(mappedBy'year'targetEntityGlobalSchoolBreak::class)]
  171.     private Collection $globalSchoolBreaks;
  172.     #[ORM\OneToMany(mappedBy'year'targetEntityTeacherAbsence::class, orphanRemovaltrue)]
  173.     private Collection $teacherAbsences;
  174.     #[ORM\OneToMany(mappedBy'year'targetEntityAttendanceMissed::class)]
  175.     private Collection $attendanceMisseds;
  176.     #[ORM\OneToMany(mappedBy'year'targetEntityGeneralBreak::class, orphanRemovaltrue)]
  177.     private Collection $generalBreaks;
  178.     #[ORM\Column(nullabletrue)]
  179.     private ?int $level null;
  180.     public function __construct()
  181.     {
  182.         $this->userYears = new ArrayCollection();
  183.         $this->studentYears = new ArrayCollection();
  184.         $this->homeWorks = new ArrayCollection();
  185.         $this->homeWorkYears = new ArrayCollection();
  186.         $this->lates = new ArrayCollection();
  187.         $this->chats = new ArrayCollection();
  188.         $this->absences = new ArrayCollection();
  189.         $this->notes = new ArrayCollection();
  190.         $this->exams = new ArrayCollection();
  191.         $this->docInfos = new ArrayCollection();
  192.         $this->punishes = new ArrayCollection();
  193.         $this->discussions = new ArrayCollection();
  194.         $this->discussionClasses = new ArrayCollection();
  195.         $this->agendas = new ArrayCollection();
  196.         $this->examAgendas = new ArrayCollection();
  197.         $this->quarters = new ArrayCollection();
  198.         $this->globalQuarters = new ArrayCollection();
  199.         $this->appreciations = new ArrayCollection();
  200.         $this->localAccounts = new ArrayCollection();
  201.         $this->disciplineWarnings = new ArrayCollection();
  202.         $this->disciplineBlames = new ArrayCollection();
  203.         $this->disciplineExclusions = new ArrayCollection();
  204.         $this->parentNotes = new ArrayCollection();
  205.         $this->justifyAbsences = new ArrayCollection();
  206.         $this->subjects = new ArrayCollection();
  207.         $this->subjectReferences = new ArrayCollection();
  208.         $this->absenceRetainedConfigs = new ArrayCollection();
  209.         $this->absenceWarningConfigs = new ArrayCollection();
  210.         $this->absenceExclusionConfigs = new ArrayCollection();
  211.         $this->absenceBlameConfigs = new ArrayCollection();
  212.         $this->disciplineRetaineds = new ArrayCollection();
  213.         $this->definitiveExclusions = new ArrayCollection();
  214.         $this->disciplineConciles = new ArrayCollection();
  215.         $this->absenceDisciplineConcileConfigs = new ArrayCollection();
  216.         $this->warningBlameConfigs = new ArrayCollection();
  217.         $this->warningDefinitiveExlusionConfigs = new ArrayCollection();
  218.         $this->primaryParentNotes = new ArrayCollection();
  219.         $this->primaryNotes = new ArrayCollection();
  220.         $this->verbalProcessCategories = new ArrayCollection();
  221.         $this->globalDisciplineConfigs = new ArrayCollection();
  222.         $this->disciplinePunishes = new ArrayCollection();
  223.         $this->globalDisciplineEnabledConfigs = new ArrayCollection();
  224.         $this->blamePunishConfigs = new ArrayCollection();
  225.         $this->absencePunishConfigs = new ArrayCollection();
  226.         $this->warningPunishConfigs = new ArrayCollection();
  227.         $this->punishRetainedConfigs = new ArrayCollection();
  228.         $this->punishWarningConfigs = new ArrayCollection();
  229.         $this->punishBlameConfigs = new ArrayCollection();
  230.         $this->punishExclusionConfigs = new ArrayCollection();
  231.         $this->schoolYearInfos = new ArrayCollection();
  232.         $this->blames = new ArrayCollection();
  233.         $this->warnings = new ArrayCollection();
  234.         $this->retaineds = new ArrayCollection();
  235.         $this->honnorTableLimitMoys = new ArrayCollection();
  236.         $this->news = new ArrayCollection();
  237.         $this->events = new ArrayCollection();
  238.         $this->admissionLimits = new ArrayCollection();
  239.         $this->examWeeks = new ArrayCollection();
  240.         $this->competences = new ArrayCollection();
  241.         $this->weekSubjectGoals = new ArrayCollection();
  242.         $this->profSchoolPlanners = new ArrayCollection();
  243.         $this->profTimes = new ArrayCollection();
  244.         $this->schoolPlannerTypes = new ArrayCollection();
  245.         $this->agendaElements = new ArrayCollection();
  246.         $this->globalSchoolBreaks = new ArrayCollection();
  247.         $this->teacherAbsences = new ArrayCollection();
  248.         $this->attendanceMisseds = new ArrayCollection();
  249.         $this->generalBreaks = new ArrayCollection();
  250.     }
  251.     public function getId(): ?int
  252.     {
  253.         return $this->id;
  254.     }
  255.     public function getName(): ?string
  256.     {
  257.         return $this->name;
  258.     }
  259.     public function setName(string $name): static
  260.     {
  261.         $this->name $name;
  262.         return $this;
  263.     }
  264.     public function isActive(): ?bool
  265.     {
  266.         return $this->active;
  267.     }
  268.     public function setActive(bool $active): static
  269.     {
  270.         $this->active $active;
  271.         return $this;
  272.     }
  273.     /**
  274.      * @return Collection<int, UserYear>
  275.      */
  276.     public function getUserYears(): Collection
  277.     {
  278.         return $this->userYears;
  279.     }
  280.     public function addUserYear(UserYear $userYear): static
  281.     {
  282.         if (!$this->userYears->contains($userYear)) {
  283.             $this->userYears->add($userYear);
  284.             $userYear->setYear($this);
  285.         }
  286.         return $this;
  287.     }
  288.     public function removeUserYear(UserYear $userYear): static
  289.     {
  290.         if ($this->userYears->removeElement($userYear)) {
  291.             // set the owning side to null (unless already changed)
  292.             if ($userYear->getYear() === $this) {
  293.                 $userYear->setYear(null);
  294.             }
  295.         }
  296.         return $this;
  297.     }
  298.     /**
  299.      * @return Collection<int, StudentYear>
  300.      */
  301.     public function getStudentYears(): Collection
  302.     {
  303.         return $this->studentYears;
  304.     }
  305.     public function addStudentYear(StudentYear $studentYear): static
  306.     {
  307.         if (!$this->studentYears->contains($studentYear)) {
  308.             $this->studentYears->add($studentYear);
  309.             $studentYear->setYear($this);
  310.         }
  311.         return $this;
  312.     }
  313.     public function removeStudentYear(StudentYear $studentYear): static
  314.     {
  315.         if ($this->studentYears->removeElement($studentYear)) {
  316.             // set the owning side to null (unless already changed)
  317.             if ($studentYear->getYear() === $this) {
  318.                 $studentYear->setYear(null);
  319.             }
  320.         }
  321.         return $this;
  322.     }
  323.     /**
  324.      * @return Collection<int, HomeWork>
  325.      */
  326.     public function getHomeWorks(): Collection
  327.     {
  328.         return $this->homeWorks;
  329.     }
  330.     public function addHomeWork(HomeWork $homeWork): static
  331.     {
  332.         if (!$this->homeWorks->contains($homeWork)) {
  333.             $this->homeWorks->add($homeWork);
  334.             $homeWork->setYear($this);
  335.         }
  336.         return $this;
  337.     }
  338.     public function removeHomeWork(HomeWork $homeWork): static
  339.     {
  340.         if ($this->homeWorks->removeElement($homeWork)) {
  341.             // set the owning side to null (unless already changed)
  342.             if ($homeWork->getYear() === $this) {
  343.                 $homeWork->setYear(null);
  344.             }
  345.         }
  346.         return $this;
  347.     }
  348.     /**
  349.      * @return Collection<int, HomeWorkYear>
  350.      */
  351.     public function getHomeWorkYears(): Collection
  352.     {
  353.         return $this->homeWorkYears;
  354.     }
  355.     public function addHomeWorkYear(HomeWorkYear $homeWorkYear): static
  356.     {
  357.         if (!$this->homeWorkYears->contains($homeWorkYear)) {
  358.             $this->homeWorkYears->add($homeWorkYear);
  359.             $homeWorkYear->setYear($this);
  360.         }
  361.         return $this;
  362.     }
  363.     public function removeHomeWorkYear(HomeWorkYear $homeWorkYear): static
  364.     {
  365.         if ($this->homeWorkYears->removeElement($homeWorkYear)) {
  366.             // set the owning side to null (unless already changed)
  367.             if ($homeWorkYear->getYear() === $this) {
  368.                 $homeWorkYear->setYear(null);
  369.             }
  370.         }
  371.         return $this;
  372.     }
  373.     /**
  374.      * @return Collection<int, Late>
  375.      */
  376.     public function getLates(): Collection
  377.     {
  378.         return $this->lates;
  379.     }
  380.     public function addLate(Late $late): static
  381.     {
  382.         if (!$this->lates->contains($late)) {
  383.             $this->lates->add($late);
  384.             $late->setYear($this);
  385.         }
  386.         return $this;
  387.     }
  388.     public function removeLate(Late $late): static
  389.     {
  390.         if ($this->lates->removeElement($late)) {
  391.             // set the owning side to null (unless already changed)
  392.             if ($late->getYear() === $this) {
  393.                 $late->setYear(null);
  394.             }
  395.         }
  396.         return $this;
  397.     }
  398.     /**
  399.      * @return Collection<int, Chat>
  400.      */
  401.     public function getChats(): Collection
  402.     {
  403.         return $this->chats;
  404.     }
  405.     public function addChat(Chat $chat): static
  406.     {
  407.         if (!$this->chats->contains($chat)) {
  408.             $this->chats->add($chat);
  409.             $chat->setYear($this);
  410.         }
  411.     }
  412.     /** 
  413.      * @return Collection<int, Absence>
  414.     */
  415.     public function getAbsences(): Collection
  416.     {
  417.         return $this->absences;
  418.     }
  419.     public function addAbsence(Absence $absence): static
  420.     {
  421.         if (!$this->absences->contains($absence)) {
  422.             $this->absences->add($absence);
  423.             $absence->setYear($this);
  424.         }
  425.         return $this;
  426.     }
  427.     public function removeChat(Chat $chat): static
  428.     {
  429.         if ($this->chats->removeElement($chat)) {
  430.             // set the owning side to null (unless already changed)
  431.             if ($chat->getYear() === $this) {
  432.                 $chat->setYear(null);
  433.             }
  434.         }
  435.         return $this;
  436.     }
  437.     public function removeAbsence(Absence $absence): static
  438.     {
  439.         if ($this->absences->removeElement($absence)) {
  440.             // set the owning side to null (unless already changed)
  441.             if ($absence->getYear() === $this) {
  442.                 $absence->setYear(null);
  443.             }
  444.         }
  445.         return $this;
  446.     }
  447.     /**
  448.      * @return Collection<int, Note>
  449.      */
  450.     public function getNotes(): Collection
  451.     {
  452.         return $this->notes;
  453.     }
  454.     public function addNote(Note $note): static
  455.     {
  456.         if (!$this->notes->contains($note)) {
  457.             $this->notes->add($note);
  458.             $note->setYear($this);
  459.         }
  460.         return $this;
  461.     }
  462.     public function removeNote(Note $note): static
  463.     {
  464.         if ($this->notes->removeElement($note)) {
  465.             // set the owning side to null (unless already changed)
  466.             if ($note->getYear() === $this) {
  467.                 $note->setYear(null);
  468.             }
  469.         }
  470.         return $this;
  471.     }
  472.     /**
  473.      * @return Collection<int, Exams>
  474.      */
  475.     public function getExams(): Collection
  476.     {
  477.         return $this->exams;
  478.     }
  479.     public function addExam(Exams $exam): static
  480.     {
  481.         if (!$this->exams->contains($exam)) {
  482.             $this->exams->add($exam);
  483.             $exam->setYear($this);
  484.         }
  485.         return $this;
  486.     }
  487.     public function removeExam(Exams $exam): static
  488.     {
  489.         if ($this->exams->removeElement($exam)) {
  490.             // set the owning side to null (unless already changed)
  491.             if ($exam->getYear() === $this) {
  492.                 $exam->setYear(null);
  493.             }
  494.         }
  495.         return $this;
  496.     }
  497.     /**
  498.      * @return Collection<int, DocInfo>
  499.      */
  500.     public function getDocInfos(): Collection
  501.     {
  502.         return $this->docInfos;
  503.     }
  504.     public function addDocInfo(DocInfo $docInfo): static
  505.     {
  506.         if (!$this->docInfos->contains($docInfo)) {
  507.             $this->docInfos->add($docInfo);
  508.             $docInfo->setYear($this);
  509.         }
  510.         return $this;
  511.     }
  512.     public function removeDocInfo(DocInfo $docInfo): static
  513.     {
  514.         if ($this->docInfos->removeElement($docInfo)) {
  515.             // set the owning side to null (unless already changed)
  516.             if ($docInfo->getYear() === $this) {
  517.                 $docInfo->setYear(null);
  518.             }
  519.         }
  520.         return $this;
  521.     }
  522.     public function getAuthor(): ?User
  523.     {
  524.         return $this->author;
  525.     }
  526.     public function setAuthor(?User $author): static
  527.     {
  528.         $this->author $author;
  529.         return $this;
  530.     }
  531.     
  532.     /**
  533.      * @return Collection<int, Punish>
  534.      */
  535.     public function getPunishes(): Collection
  536.     {
  537.         return $this->punishes;
  538.     }
  539.     public function addPunish(Punish $punish): static
  540.     {
  541.         if (!$this->punishes->contains($punish)) {
  542.             $this->punishes->add($punish);
  543.             $punish->setYear($this);
  544.         }
  545.         return $this;
  546.     }
  547.     public function removePunish(Punish $punish): static
  548.     {
  549.         if ($this->punishes->removeElement($punish)) {
  550.             // set the owning side to null (unless already changed)
  551.             if ($punish->getYear() === $this) {
  552.                 $punish->setYear(null);
  553.             }
  554.         }
  555.         return $this;
  556.     }
  557.     public function getEditor(): ?User
  558.     {
  559.         return $this->editor;
  560.     }
  561.     public function setEditor(?User $editor): static
  562.     {
  563.         $this->editor $editor;
  564.         return $this;
  565.     }
  566.     /**
  567.      * @return Collection<int, Discussion>
  568.      */
  569.     public function getDiscussions(): Collection
  570.     {
  571.         return $this->discussions;
  572.     }
  573.     public function addDiscussion(Discussion $discussion): static
  574.     {
  575.         if (!$this->discussions->contains($discussion)) {
  576.             $this->discussions->add($discussion);
  577.             $discussion->setYear($this);
  578.         }
  579.         return $this;
  580.     }
  581.     public function removeDiscussion(Discussion $discussion): static
  582.     {
  583.         if ($this->discussions->removeElement($discussion)) {
  584.             // set the owning side to null (unless already changed)
  585.             if ($discussion->getYear() === $this) {
  586.                 $discussion->setYear(null);
  587.             }
  588.         }
  589.         return $this;
  590.     }
  591.     /**
  592.      * @return Collection<int, DiscussionClass>
  593.      */
  594.     public function getDiscussionClasses(): Collection
  595.     {
  596.         return $this->discussionClasses;
  597.     }
  598.     public function addDiscussionClass(DiscussionClass $discussionClass): static
  599.     {
  600.         if (!$this->discussionClasses->contains($discussionClass)) {
  601.             $this->discussionClasses->add($discussionClass);
  602.             $discussionClass->setYear($this);
  603.         }
  604.         return $this;
  605.     }
  606.     public function removeDiscussionClass(DiscussionClass $discussionClass): static
  607.     {
  608.         if ($this->discussionClasses->removeElement($discussionClass)) {
  609.             // set the owning side to null (unless already changed)
  610.             if ($discussionClass->getYear() === $this) {
  611.                 $discussionClass->setYear(null);
  612.             }
  613.         }
  614.         return $this;
  615.     }
  616.     /**
  617.      * @return Collection<int, Agenda>
  618.      */
  619.     public function getAgendas(): Collection
  620.     {
  621.         return $this->agendas;
  622.     }
  623.     public function addAgenda(Agenda $agenda): static
  624.     {
  625.         if (!$this->agendas->contains($agenda)) {
  626.             $this->agendas->add($agenda);
  627.             $agenda->setYear($this);
  628.         }
  629.         return $this;
  630.     }
  631.     public function removeAgenda(Agenda $agenda): static
  632.     {
  633.         if ($this->agendas->removeElement($agenda)) {
  634.             // set the owning side to null (unless already changed)
  635.             if ($agenda->getYear() === $this) {
  636.                 $agenda->setYear(null);
  637.             }
  638.         }
  639.         return $this;
  640.     }
  641.     /**
  642.      * @return Collection<int, ExamAgenda>
  643.      */
  644.     public function getExamAgendas(): Collection
  645.     {
  646.         return $this->examAgendas;
  647.     }
  648.     public function addExamAgenda(ExamAgenda $examAgenda): static
  649.     {
  650.         if (!$this->examAgendas->contains($examAgenda)) {
  651.             $this->examAgendas->add($examAgenda);
  652.             $examAgenda->setYear($this);
  653.         }
  654.         return $this;
  655.     }
  656.     public function removeExamAgenda(ExamAgenda $examAgenda): static
  657.     {
  658.         if ($this->examAgendas->removeElement($examAgenda)) {
  659.             // set the owning side to null (unless already changed)
  660.             if ($examAgenda->getYear() === $this) {
  661.                 $examAgenda->setYear(null);
  662.             }
  663.         }
  664.         return $this;
  665.     }
  666.     /**
  667.      * @return Collection<int, Quarter>
  668.      */
  669.     public function getQuarters(): Collection
  670.     {
  671.         return $this->quarters;
  672.     }
  673.     public function addQuarter(Quarter $quarter): static
  674.     {
  675.         if (!$this->quarters->contains($quarter)) {
  676.             $this->quarters->add($quarter);
  677.             $quarter->setYear($this);
  678.         }
  679.         return $this;
  680.     }
  681.     public function removeQuarter(Quarter $quarter): static
  682.     {
  683.         if ($this->quarters->removeElement($quarter)) {
  684.             // set the owning side to null (unless already changed)
  685.             if ($quarter->getYear() === $this) {
  686.                 $quarter->setYear(null);
  687.             }
  688.         }
  689.         return $this;
  690.     }
  691.     /**
  692.      * @return Collection<int, GlobalQuarter>
  693.      */
  694.     public function getGlobalQuarters(): Collection
  695.     {
  696.         return $this->globalQuarters;
  697.     }
  698.     public function addGlobalQuarter(GlobalQuarter $globalQuarter): static
  699.     {
  700.         if (!$this->globalQuarters->contains($globalQuarter)) {
  701.             $this->globalQuarters->add($globalQuarter);
  702.             $globalQuarter->setYear($this);
  703.         }
  704.         return $this;
  705.     }
  706.     public function removeGlobalQuarter(GlobalQuarter $globalQuarter): static
  707.     {
  708.         if ($this->globalQuarters->removeElement($globalQuarter)) {
  709.             // set the owning side to null (unless already changed)
  710.             if ($globalQuarter->getYear() === $this) {
  711.                 $globalQuarter->setYear(null);
  712.             }
  713.         }
  714.         return $this;
  715.     }
  716.     /**
  717.      * @return Collection<int, LocalAccount>
  718.      */
  719.     public function getLocalAccounts(): Collection
  720.     {
  721.         return $this->localAccounts;
  722.     }
  723.     public function addLocalAccount(LocalAccount $localAccount): static
  724.     {
  725.         if (!$this->localAccounts->contains($localAccount)) {
  726.             $this->localAccounts->add($localAccount);
  727.             $localAccount->setYear($this);
  728.         }
  729.         return $this;
  730.     }
  731.     public function removeLocalAccount(LocalAccount $localAccount): static
  732.     {
  733.         if ($this->localAccounts->removeElement($localAccount)) {
  734.             // set the owning side to null (unless already changed)
  735.             if ($localAccount->getYear() === $this) {
  736.                 $localAccount->setYear(null);
  737.             }
  738.         }
  739.         return $this;
  740.     }
  741.     /**
  742.      * @return Collection<int, Appreciation>
  743.      */
  744.     public function getAppreciations(): Collection
  745.     {
  746.         return $this->appreciations;
  747.     }
  748.     public function addAppreciation(Appreciation $appreciation): static
  749.     {
  750.         if (!$this->appreciations->contains($appreciation)) {
  751.             $this->appreciations->add($appreciation);
  752.             $appreciation->setYear($this);
  753.         }
  754.         return $this;
  755.     }
  756.     public function removeAppreciation(Appreciation $appreciation): static
  757.     {
  758.         if ($this->appreciations->removeElement($appreciation)) {
  759.             // set the owning side to null (unless already changed)
  760.             if ($appreciation->getYear() === $this) {
  761.                 $appreciation->setYear(null);
  762.             }
  763.         }
  764.         return $this;
  765.     }
  766.     /**
  767.      * @return Collection<int, DisciplineWarning>
  768.      */
  769.     public function getDisciplineWarnings(): Collection
  770.     {
  771.         return $this->disciplineWarnings;
  772.     }
  773.     public function addDisciplineWarning(DisciplineWarning $disciplineWarning): static
  774.     {
  775.         if (!$this->disciplineWarnings->contains($disciplineWarning)) {
  776.             $this->disciplineWarnings->add($disciplineWarning);
  777.             $disciplineWarning->setYear($this);
  778.         }
  779.         return $this;
  780.     }
  781.     public function removeDisciplineWarning(DisciplineWarning $disciplineWarning): static
  782.     {
  783.         if ($this->disciplineWarnings->removeElement($disciplineWarning)) {
  784.             // set the owning side to null (unless already changed)
  785.             if ($disciplineWarning->getYear() === $this) {
  786.                 $disciplineWarning->setYear(null);
  787.             }
  788.         }
  789.         return $this;
  790.     }
  791.     /**
  792.      * @return Collection<int, DisciplineBlame>
  793.      */
  794.     public function getDisciplineBlames(): Collection
  795.     {
  796.         return $this->disciplineBlames;
  797.     }
  798.     public function addDisciplineBlame(DisciplineBlame $disciplineBlame): static
  799.     {
  800.         if (!$this->disciplineBlames->contains($disciplineBlame)) {
  801.             $this->disciplineBlames->add($disciplineBlame);
  802.             $disciplineBlame->setYear($this);
  803.         }
  804.         return $this;
  805.     }
  806.     public function removeDisciplineBlame(DisciplineBlame $disciplineBlame): static
  807.     {
  808.         if ($this->disciplineBlames->removeElement($disciplineBlame)) {
  809.             // set the owning side to null (unless already changed)
  810.             if ($disciplineBlame->getYear() === $this) {
  811.                 $disciplineBlame->setYear(null);
  812.             }
  813.         }
  814.         return $this;
  815.     }
  816.     /**
  817.      * @return Collection<int, DisciplineExclusion>
  818.      */
  819.     public function getDisciplineExclusions(): Collection
  820.     {
  821.         return $this->disciplineExclusions;
  822.     }
  823.     public function addDisciplineExclusion(DisciplineExclusion $disciplineExclusion): static
  824.     {
  825.         if (!$this->disciplineExclusions->contains($disciplineExclusion)) {
  826.             $this->disciplineExclusions->add($disciplineExclusion);
  827.             $disciplineExclusion->setYear($this);
  828.         }
  829.         return $this;
  830.     }
  831.     public function removeDisciplineExclusion(DisciplineExclusion $disciplineExclusion): static
  832.     {
  833.         if ($this->disciplineExclusions->removeElement($disciplineExclusion)) {
  834.             // set the owning side to null (unless already changed)
  835.             if ($disciplineExclusion->getYear() === $this) {
  836.                 $disciplineExclusion->setYear(null);
  837.             }
  838.         }
  839.         return $this;
  840.     }
  841.     /**
  842.      * @return Collection<int, ParentNote>
  843.      */
  844.     public function getParentNotes(): Collection
  845.     {
  846.         return $this->parentNotes;
  847.     }
  848.     public function addParentNote(ParentNote $parentNote): static
  849.     {
  850.         if (!$this->parentNotes->contains($parentNote)) {
  851.             $this->parentNotes->add($parentNote);
  852.             $parentNote->setYear($this);
  853.         }
  854.         return $this;
  855.     }
  856.     public function removeParentNote(ParentNote $parentNote): static
  857.     {
  858.         if ($this->parentNotes->removeElement($parentNote)) {
  859.             // set the owning side to null (unless already changed)
  860.             if ($parentNote->getYear() === $this) {
  861.                 $parentNote->setYear(null);
  862.             }
  863.         }
  864.         return $this;
  865.     }
  866.     /**
  867.      * @return Collection<int, JustifyAbsence>
  868.      */
  869.     public function getJustifyAbsences(): Collection
  870.     {
  871.         return $this->justifyAbsences;
  872.     }
  873.     public function addJustifyAbsence(JustifyAbsence $justifyAbsence): static
  874.     {
  875.         if (!$this->justifyAbsences->contains($justifyAbsence)) {
  876.             $this->justifyAbsences->add($justifyAbsence);
  877.             $justifyAbsence->setYear($this);
  878.         }
  879.         return $this;
  880.     }
  881.     public function removeJustifyAbsence(JustifyAbsence $justifyAbsence): static
  882.     {
  883.         if ($this->justifyAbsences->removeElement($justifyAbsence)) {
  884.             // set the owning side to null (unless already changed)
  885.             if ($justifyAbsence->getYear() === $this) {
  886.                 $justifyAbsence->setYear(null);
  887.             }
  888.         }
  889.         return $this;
  890.     }
  891.     /**
  892.      * @return Collection<int, Subject>
  893.      */
  894.     public function getSubjects(): Collection
  895.     {
  896.         return $this->subjects;
  897.     }
  898.     public function addSubject(Subject $subject): static
  899.     {
  900.         if (!$this->subjects->contains($subject)) {
  901.             $this->subjects->add($subject);
  902.             $subject->setYear($this);
  903.         }
  904.         return $this;
  905.     }
  906.     public function removeSubject(Subject $subject): static
  907.     {
  908.         if ($this->subjects->removeElement($subject)) {
  909.             // set the owning side to null (unless already changed)
  910.             if ($subject->getYear() === $this) {
  911.                 $subject->setYear(null);
  912.             }
  913.         }
  914.         return $this;
  915.     }
  916.     /**
  917.      * @return Collection<int, SubjectReference>
  918.      */
  919.     public function getSubjectReferences(): Collection
  920.     {
  921.         return $this->subjectReferences;
  922.     }
  923.     public function addSubjectReference(SubjectReference $subjectReference): static
  924.     {
  925.         if (!$this->subjectReferences->contains($subjectReference)) {
  926.             $this->subjectReferences->add($subjectReference);
  927.             $subjectReference->setYear($this);
  928.         }
  929.         return $this;
  930.     }
  931.     public function removeSubjectReference(SubjectReference $subjectReference): static
  932.     {
  933.         if ($this->subjectReferences->removeElement($subjectReference)) {
  934.             if ($subjectReference->getYear() === $this) {
  935.                 $subjectReference->setYear(null);
  936.             }
  937.         }
  938.         return $this;
  939.     }
  940.     /**
  941.      * @return Collection<int, AbsenceRetainedConfig>
  942.      */
  943.     public function getAbsenceRetainedConfigs(): Collection
  944.     {
  945.         return $this->absenceRetainedConfigs;
  946.     }
  947.     public function addAbsenceRetainedConfig(AbsenceRetainedConfig $absenceRetainedConfig): static
  948.     {
  949.         if (!$this->absenceRetainedConfigs->contains($absenceRetainedConfig)) {
  950.             $this->absenceRetainedConfigs->add($absenceRetainedConfig);
  951.             $absenceRetainedConfig->setYear($this);
  952.         }
  953.         return $this;
  954.     }
  955.     public function removeAbsenceRetainedConfig(AbsenceRetainedConfig $absenceRetainedConfig): static
  956.     {
  957.         if ($this->absenceRetainedConfigs->removeElement($absenceRetainedConfig)) {
  958.             // set the owning side to null (unless already changed)
  959.             if ($absenceRetainedConfig->getYear() === $this) {
  960.                 $absenceRetainedConfig->setYear(null);
  961.             }
  962.         }
  963.         return $this;
  964.     }
  965.     /**
  966.      * @return Collection<int, AbsenceWarningConfig>
  967.      */
  968.     public function getAbsenceWarningConfigs(): Collection
  969.     {
  970.         return $this->absenceWarningConfigs;
  971.     }
  972.     public function addAbsenceWarningConfig(AbsenceWarningConfig $absenceWarningConfig): static
  973.     {
  974.         if (!$this->absenceWarningConfigs->contains($absenceWarningConfig)) {
  975.             $this->absenceWarningConfigs->add($absenceWarningConfig);
  976.             $absenceWarningConfig->setYear($this);
  977.         }
  978.         return $this;
  979.     }
  980.     public function removeAbsenceWarningConfig(AbsenceWarningConfig $absenceWarningConfig): static
  981.     {
  982.         if ($this->absenceWarningConfigs->removeElement($absenceWarningConfig)) {
  983.             // set the owning side to null (unless already changed)
  984.             if ($absenceWarningConfig->getYear() === $this) {
  985.                 $absenceWarningConfig->setYear(null);
  986.             }
  987.         }
  988.         return $this;
  989.     }
  990.     /**
  991.      * @return Collection<int, AbsenceExclusionConfig>
  992.      */
  993.     public function getAbsenceExclusionConfigs(): Collection
  994.     {
  995.         return $this->absenceExclusionConfigs;
  996.     }
  997.     public function addAbsenceExclusionConfig(AbsenceExclusionConfig $absenceExclusionConfig): static
  998.     {
  999.         if (!$this->absenceExclusionConfigs->contains($absenceExclusionConfig)) {
  1000.             $this->absenceExclusionConfigs->add($absenceExclusionConfig);
  1001.             $absenceExclusionConfig->setYear($this);
  1002.         }
  1003.         return $this;
  1004.     }
  1005.     public function removeAbsenceExclusionConfig(AbsenceExclusionConfig $absenceExclusionConfig): static
  1006.     {
  1007.         if ($this->absenceExclusionConfigs->removeElement($absenceExclusionConfig)) {
  1008.             // set the owning side to null (unless already changed)
  1009.             if ($absenceExclusionConfig->getYear() === $this) {
  1010.                 $absenceExclusionConfig->setYear(null);
  1011.             }
  1012.         }
  1013.         return $this;
  1014.     }
  1015.     /**
  1016.      * @return Collection<int, AbsenceBlameConfig>
  1017.      */
  1018.     public function getAbsenceBlameConfigs(): Collection
  1019.     {
  1020.         return $this->absenceBlameConfigs;
  1021.     }
  1022.     public function addAbsenceBlameConfig(AbsenceBlameConfig $absenceBlameConfig): static
  1023.     {
  1024.         if (!$this->absenceBlameConfigs->contains($absenceBlameConfig)) {
  1025.             $this->absenceBlameConfigs->add($absenceBlameConfig);
  1026.             $absenceBlameConfig->setYear($this);
  1027.         }
  1028.         return $this;
  1029.     }
  1030.     public function removeAbsenceBlameConfig(AbsenceBlameConfig $absenceBlameConfig): static
  1031.     {
  1032.         if ($this->absenceBlameConfigs->removeElement($absenceBlameConfig)) {
  1033.             // set the owning side to null (unless already changed)
  1034.             if ($absenceBlameConfig->getYear() === $this) {
  1035.                 $absenceBlameConfig->setYear(null);
  1036.             }
  1037.         }
  1038.         return $this;
  1039.     }
  1040.     /**
  1041.      * @return Collection<int, DisciplineRetained>
  1042.      */
  1043.     public function getDisciplineRetaineds(): Collection
  1044.     {
  1045.         return $this->disciplineRetaineds;
  1046.     }
  1047.     public function addDisciplineRetained(DisciplineRetained $disciplineRetained): static
  1048.     {
  1049.         if (!$this->disciplineRetaineds->contains($disciplineRetained)) {
  1050.             $this->disciplineRetaineds->add($disciplineRetained);
  1051.             $disciplineRetained->setYear($this);
  1052.         }
  1053.         return $this;
  1054.     }
  1055.     public function removeDisciplineRetained(DisciplineRetained $disciplineRetained): static
  1056.     {
  1057.         if ($this->disciplineRetaineds->removeElement($disciplineRetained)) {
  1058.             // set the owning side to null (unless already changed)
  1059.             if ($disciplineRetained->getYear() === $this) {
  1060.                 $disciplineRetained->setYear(null);
  1061.             }
  1062.         }
  1063.         return $this;
  1064.     }
  1065.     /**
  1066.      * @return Collection<int, DefinitiveExclusion>
  1067.      */
  1068.     public function getDefinitiveExclusions(): Collection
  1069.     {
  1070.         return $this->definitiveExclusions;
  1071.     }
  1072.     public function addDefinitiveExclusion(DefinitiveExclusion $definitiveExclusion): static
  1073.     {
  1074.         if (!$this->definitiveExclusions->contains($definitiveExclusion)) {
  1075.             $this->definitiveExclusions->add($definitiveExclusion);
  1076.             $definitiveExclusion->setYear($this);
  1077.         }
  1078.         return $this;
  1079.     }
  1080.     public function removeDefinitiveExclusion(DefinitiveExclusion $definitiveExclusion): static
  1081.     {
  1082.         if ($this->definitiveExclusions->removeElement($definitiveExclusion)) {
  1083.             // set the owning side to null (unless already changed)
  1084.             if ($definitiveExclusion->getYear() === $this) {
  1085.                 $definitiveExclusion->setYear(null);
  1086.             }
  1087.         }
  1088.         return $this;
  1089.     }
  1090.     /**
  1091.      * @return Collection<int, DisciplineConcile>
  1092.      */
  1093.     public function getDisciplineConciles(): Collection
  1094.     {
  1095.         return $this->disciplineConciles;
  1096.     }
  1097.     public function addDisciplineConcile(DisciplineConcile $disciplineConcile): static
  1098.     {
  1099.         if (!$this->disciplineConciles->contains($disciplineConcile)) {
  1100.             $this->disciplineConciles->add($disciplineConcile);
  1101.             $disciplineConcile->setYear($this);
  1102.         }
  1103.         return $this;
  1104.     }
  1105.     public function removeDisciplineConcile(DisciplineConcile $disciplineConcile): static
  1106.     {
  1107.         if ($this->disciplineConciles->removeElement($disciplineConcile)) {
  1108.             // set the owning side to null (unless already changed)
  1109.             if ($disciplineConcile->getYear() === $this) {
  1110.                 $disciplineConcile->setYear(null);
  1111.             }
  1112.         }
  1113.         return $this;
  1114.     }
  1115.     /**
  1116.      * @return Collection<int, AbsenceDisciplineConcileConfig>
  1117.      */
  1118.     public function getAbsenceDisciplineConcileConfigs(): Collection
  1119.     {
  1120.         return $this->absenceDisciplineConcileConfigs;
  1121.     }
  1122.     public function addAbsenceDisciplineConcileConfig(AbsenceDisciplineConcileConfig $absenceDisciplineConcileConfig): static
  1123.     {
  1124.         if (!$this->absenceDisciplineConcileConfigs->contains($absenceDisciplineConcileConfig)) {
  1125.             $this->absenceDisciplineConcileConfigs->add($absenceDisciplineConcileConfig);
  1126.             $absenceDisciplineConcileConfig->setYear($this);
  1127.         }
  1128.         return $this;
  1129.     }
  1130.     public function removeAbsenceDisciplineConcileConfig(AbsenceDisciplineConcileConfig $absenceDisciplineConcileConfig): static
  1131.     {
  1132.         if ($this->absenceDisciplineConcileConfigs->removeElement($absenceDisciplineConcileConfig)) {
  1133.             // set the owning side to null (unless already changed)
  1134.             if ($absenceDisciplineConcileConfig->getYear() === $this) {
  1135.                 $absenceDisciplineConcileConfig->setYear(null);
  1136.             }
  1137.         }
  1138.         return $this;
  1139.     }
  1140.     /**
  1141.      * @return Collection<int, WarningBlameConfig>
  1142.      */
  1143.     public function getWarningBlameConfigs(): Collection
  1144.     {
  1145.         return $this->warningBlameConfigs;
  1146.     }
  1147.     public function addWarningBlameConfig(WarningBlameConfig $warningBlameConfig): static
  1148.     {
  1149.         if (!$this->warningBlameConfigs->contains($warningBlameConfig)) {
  1150.             $this->warningBlameConfigs->add($warningBlameConfig);
  1151.             $warningBlameConfig->setYear($this);
  1152.         }
  1153.         return $this;
  1154.     }
  1155.     public function removeWarningBlameConfig(WarningBlameConfig $warningBlameConfig): static
  1156.     {
  1157.         if ($this->warningBlameConfigs->removeElement($warningBlameConfig)) {
  1158.             // set the owning side to null (unless already changed)
  1159.             if ($warningBlameConfig->getYear() === $this) {
  1160.                 $warningBlameConfig->setYear(null);
  1161.             }
  1162.         }
  1163.         return $this;
  1164.     }
  1165.     /**
  1166.      * @return Collection<int, WarningDefinitiveExlusionConfig>
  1167.      */
  1168.     public function getWarningDefinitiveExlusionConfigs(): Collection
  1169.     {
  1170.         return $this->warningDefinitiveExlusionConfigs;
  1171.     }
  1172.     public function addWarningDefinitiveExlusionConfig(WarningDefinitiveExlusionConfig $warningDefinitiveExlusionConfig): static
  1173.     {
  1174.         if (!$this->warningDefinitiveExlusionConfigs->contains($warningDefinitiveExlusionConfig)) {
  1175.             $this->warningDefinitiveExlusionConfigs->add($warningDefinitiveExlusionConfig);
  1176.             $warningDefinitiveExlusionConfig->setYear($this);
  1177.         }
  1178.         return $this;
  1179.     }
  1180.     public function removeWarningDefinitiveExlusionConfig(WarningDefinitiveExlusionConfig $warningDefinitiveExlusionConfig): static
  1181.     {
  1182.         if ($this->warningDefinitiveExlusionConfigs->removeElement($warningDefinitiveExlusionConfig)) {
  1183.             // set the owning side to null (unless already changed)
  1184.             if ($warningDefinitiveExlusionConfig->getYear() === $this) {
  1185.                 $warningDefinitiveExlusionConfig->setYear(null);
  1186.             }
  1187.         }
  1188.         return $this;
  1189.     }
  1190.     /**
  1191.      * @return Collection<int, PrimaryParentNote>
  1192.      */
  1193.     public function getPrimaryParentNotes(): Collection
  1194.     {
  1195.         return $this->primaryParentNotes;
  1196.     }
  1197.     public function addPrimaryParentNote(PrimaryParentNote $primaryParentNote): static
  1198.     {
  1199.         if (!$this->primaryParentNotes->contains($primaryParentNote)) {
  1200.             $this->primaryParentNotes->add($primaryParentNote);
  1201.             $primaryParentNote->setYear($this);
  1202.         }
  1203.         return $this;
  1204.     }
  1205.     public function removePrimaryParentNote(PrimaryParentNote $primaryParentNote): static
  1206.     {
  1207.         if ($this->primaryParentNotes->removeElement($primaryParentNote)) {
  1208.             // set the owning side to null (unless already changed)
  1209.             if ($primaryParentNote->getYear() === $this) {
  1210.                 $primaryParentNote->setYear(null);
  1211.             }
  1212.         }
  1213.         return $this;
  1214.     }
  1215.     /**
  1216.      * @return Collection<int, PrimaryNote>
  1217.      */
  1218.     public function getPrimaryNotes(): Collection
  1219.     {
  1220.         return $this->primaryNotes;
  1221.     }
  1222.     public function addPrimaryNote(PrimaryNote $primaryNote): static
  1223.     {
  1224.         if (!$this->primaryNotes->contains($primaryNote)) {
  1225.             $this->primaryNotes->add($primaryNote);
  1226.             $primaryNote->setYear($this);
  1227.         }
  1228.         return $this;
  1229.     }
  1230.     public function removePrimaryNote(PrimaryNote $primaryNote): static
  1231.     {
  1232.         if ($this->primaryNotes->removeElement($primaryNote)) {
  1233.             // set the owning side to null (unless already changed)
  1234.             if ($primaryNote->getYear() === $this) {
  1235.                 $primaryNote->setYear(null);
  1236.             }
  1237.         }
  1238.         return $this;
  1239.     }
  1240.     /**
  1241.      * @return Collection<int, VerbalProcessCategory>
  1242.      */
  1243.     public function getVerbalProcessCategories(): Collection
  1244.     {
  1245.         return $this->verbalProcessCategories;
  1246.     }
  1247.     public function addVerbalProcessCategory(VerbalProcessCategory $verbalProcessCategory): static
  1248.     {
  1249.         if (!$this->verbalProcessCategories->contains($verbalProcessCategory)) {
  1250.             $this->verbalProcessCategories->add($verbalProcessCategory);
  1251.             $verbalProcessCategory->setYear($this);
  1252.         }
  1253.         return $this;
  1254.     }
  1255.     public function removeVerbalProcessCategory(VerbalProcessCategory $verbalProcessCategory): static
  1256.     {
  1257.         if ($this->verbalProcessCategories->removeElement($verbalProcessCategory)) {
  1258.             // set the owning side to null (unless already changed)
  1259.             if ($verbalProcessCategory->getYear() === $this) {
  1260.                 $verbalProcessCategory->setYear(null);
  1261.             }
  1262.         }
  1263.         return $this;
  1264.     }
  1265.     /**
  1266.      * @return Collection<int, GlobalDisciplineConfig>
  1267.      */
  1268.     public function getGlobalDisciplineConfigs(): Collection
  1269.     {
  1270.         return $this->globalDisciplineConfigs;
  1271.     }
  1272.     public function addGlobalDisciplineConfig(GlobalDisciplineConfig $globalDisciplineConfig): static
  1273.     {
  1274.         if (!$this->globalDisciplineConfigs->contains($globalDisciplineConfig)) {
  1275.             $this->globalDisciplineConfigs->add($globalDisciplineConfig);
  1276.             $globalDisciplineConfig->setYear($this);
  1277.         }
  1278.         return $this;
  1279.     }
  1280.     public function removeGlobalDisciplineConfig(GlobalDisciplineConfig $globalDisciplineConfig): static
  1281.     {
  1282.         if ($this->globalDisciplineConfigs->removeElement($globalDisciplineConfig)) {
  1283.             // set the owning side to null (unless already changed)
  1284.             if ($globalDisciplineConfig->getYear() === $this) {
  1285.                 $globalDisciplineConfig->setYear(null);
  1286.             }
  1287.         }
  1288.         return $this;
  1289.     }
  1290.     /**
  1291.      * @return Collection<int, DisciplinePunish>
  1292.      */
  1293.     public function getDisciplinePunishes(): Collection
  1294.     {
  1295.         return $this->disciplinePunishes;
  1296.     }
  1297.     public function addDisciplinePunish(DisciplinePunish $disciplinePunish): static
  1298.     {
  1299.         if (!$this->disciplinePunishes->contains($disciplinePunish)) {
  1300.             $this->disciplinePunishes->add($disciplinePunish);
  1301.             $disciplinePunish->setYear($this);
  1302.         }
  1303.         return $this;
  1304.     }
  1305.     public function removeDisciplinePunish(DisciplinePunish $disciplinePunish): static
  1306.     {
  1307.         if ($this->disciplinePunishes->removeElement($disciplinePunish)) {
  1308.             // set the owning side to null (unless already changed)
  1309.             if ($disciplinePunish->getYear() === $this) {
  1310.                 $disciplinePunish->setYear(null);
  1311.             }
  1312.         }
  1313.         return $this;
  1314.     }
  1315.     /**
  1316.      * @return Collection<int, GlobalDisciplineEnabledConfig>
  1317.      */
  1318.     public function getGlobalDisciplineEnabledConfigs(): Collection
  1319.     {
  1320.         return $this->globalDisciplineEnabledConfigs;
  1321.     }
  1322.     public function addGlobalDisciplineEnabledConfig(GlobalDisciplineEnabledConfig $globalDisciplineEnabledConfig): static
  1323.     {
  1324.         if (!$this->globalDisciplineEnabledConfigs->contains($globalDisciplineEnabledConfig)) {
  1325.             $this->globalDisciplineEnabledConfigs->add($globalDisciplineEnabledConfig);
  1326.             $globalDisciplineEnabledConfig->setYear($this);
  1327.         }
  1328.         return $this;
  1329.     }
  1330.     public function removeGlobalDisciplineEnabledConfig(GlobalDisciplineEnabledConfig $globalDisciplineEnabledConfig): static
  1331.     {
  1332.         if ($this->globalDisciplineEnabledConfigs->removeElement($globalDisciplineEnabledConfig)) {
  1333.             // set the owning side to null (unless already changed)
  1334.             if ($globalDisciplineEnabledConfig->getYear() === $this) {
  1335.                 $globalDisciplineEnabledConfig->setYear(null);
  1336.             }
  1337.         }
  1338.         return $this;
  1339.     }
  1340.     /**
  1341.      * @return Collection<int, BlamePunishConfig>
  1342.      */
  1343.     public function getBlamePunishConfigs(): Collection
  1344.     {
  1345.         return $this->blamePunishConfigs;
  1346.     }
  1347.     public function addBlamePunishConfig(BlamePunishConfig $blamePunishConfig): static
  1348.     {
  1349.         if (!$this->blamePunishConfigs->contains($blamePunishConfig)) {
  1350.             $this->blamePunishConfigs->add($blamePunishConfig);
  1351.             $blamePunishConfig->setYear($this);
  1352.         }
  1353.         return $this;
  1354.     }
  1355.     public function removeBlamePunishConfig(BlamePunishConfig $blamePunishConfig): static
  1356.     {
  1357.         if ($this->blamePunishConfigs->removeElement($blamePunishConfig)) {
  1358.             // set the owning side to null (unless already changed)
  1359.             if ($blamePunishConfig->getYear() === $this) {
  1360.                 $blamePunishConfig->setYear(null);
  1361.             }
  1362.         }
  1363.         return $this;
  1364.     }
  1365.     /**
  1366.      * @return Collection<int, AbsencePunishConfig>
  1367.      */
  1368.     public function getAbsencePunishConfigs(): Collection
  1369.     {
  1370.         return $this->absencePunishConfigs;
  1371.     }
  1372.     public function addAbsencePunishConfig(AbsencePunishConfig $absencePunishConfig): static
  1373.     {
  1374.         if (!$this->absencePunishConfigs->contains($absencePunishConfig)) {
  1375.             $this->absencePunishConfigs->add($absencePunishConfig);
  1376.             $absencePunishConfig->setYear($this);
  1377.         }
  1378.         return $this;
  1379.     }
  1380.     public function removeAbsencePunishConfig(AbsencePunishConfig $absencePunishConfig): static
  1381.     {
  1382.         if ($this->absencePunishConfigs->removeElement($absencePunishConfig)) {
  1383.             // set the owning side to null (unless already changed)
  1384.             if ($absencePunishConfig->getYear() === $this) {
  1385.                 $absencePunishConfig->setYear(null);
  1386.             }
  1387.         }
  1388.         return $this;
  1389.     }
  1390.     /**
  1391.      * @return Collection<int, WarningPunishConfig>
  1392.      */
  1393.     public function getWarningPunishConfigs(): Collection
  1394.     {
  1395.         return $this->warningPunishConfigs;
  1396.     }
  1397.     public function addWarningPunishConfig(WarningPunishConfig $warningPunishConfig): static
  1398.     {
  1399.         if (!$this->warningPunishConfigs->contains($warningPunishConfig)) {
  1400.             $this->warningPunishConfigs->add($warningPunishConfig);
  1401.             $warningPunishConfig->setYear($this);
  1402.         }
  1403.         return $this;
  1404.     }
  1405.     public function removeWarningPunishConfig(WarningPunishConfig $warningPunishConfig): static
  1406.     {
  1407.         if ($this->warningPunishConfigs->removeElement($warningPunishConfig)) {
  1408.             // set the owning side to null (unless already changed)
  1409.             if ($warningPunishConfig->getYear() === $this) {
  1410.                 $warningPunishConfig->setYear(null);
  1411.             }
  1412.         }
  1413.         return $this;
  1414.     }
  1415.     /**
  1416.      * @return Collection<int, PunishRetainedConfig>
  1417.      */
  1418.     public function getPunishRetainedConfigs(): Collection
  1419.     {
  1420.         return $this->punishRetainedConfigs;
  1421.     }
  1422.     public function addPunishRetainedConfig(PunishRetainedConfig $punishRetainedConfig): static
  1423.     {
  1424.         if (!$this->punishRetainedConfigs->contains($punishRetainedConfig)) {
  1425.             $this->punishRetainedConfigs->add($punishRetainedConfig);
  1426.             $punishRetainedConfig->setYear($this);
  1427.         }
  1428.         return $this;
  1429.     }
  1430.     public function removePunishRetainedConfig(PunishRetainedConfig $punishRetainedConfig): static
  1431.     {
  1432.         if ($this->punishRetainedConfigs->removeElement($punishRetainedConfig)) {
  1433.             // set the owning side to null (unless already changed)
  1434.             if ($punishRetainedConfig->getYear() === $this) {
  1435.                 $punishRetainedConfig->setYear(null);
  1436.             }
  1437.         }
  1438.         return $this;
  1439.     }
  1440.     /**
  1441.      * @return Collection<int, PunishWarningConfig>
  1442.      */
  1443.     public function getPunishWarningConfigs(): Collection
  1444.     {
  1445.         return $this->punishWarningConfigs;
  1446.     }
  1447.     public function addPunishWarningConfig(PunishWarningConfig $punishWarningConfig): static
  1448.     {
  1449.         if (!$this->punishWarningConfigs->contains($punishWarningConfig)) {
  1450.             $this->punishWarningConfigs->add($punishWarningConfig);
  1451.             $punishWarningConfig->setYear($this);
  1452.         }
  1453.         return $this;
  1454.     }
  1455.     public function removePunishWarningConfig(PunishWarningConfig $punishWarningConfig): static
  1456.     {
  1457.         if ($this->punishWarningConfigs->removeElement($punishWarningConfig)) {
  1458.             // set the owning side to null (unless already changed)
  1459.             if ($punishWarningConfig->getYear() === $this) {
  1460.                 $punishWarningConfig->setYear(null);
  1461.             }
  1462.         }
  1463.         return $this;
  1464.     }
  1465.     /**
  1466.      * @return Collection<int, PunishBlameConfig>
  1467.      */
  1468.     public function getPunishBlameConfigs(): Collection
  1469.     {
  1470.         return $this->punishBlameConfigs;
  1471.     }
  1472.     public function addPunishBlameConfig(PunishBlameConfig $punishBlameConfig): static
  1473.     {
  1474.         if (!$this->punishBlameConfigs->contains($punishBlameConfig)) {
  1475.             $this->punishBlameConfigs->add($punishBlameConfig);
  1476.             $punishBlameConfig->setYear($this);
  1477.         }
  1478.         return $this;
  1479.     }
  1480.     public function removePunishBlameConfig(PunishBlameConfig $punishBlameConfig): static
  1481.     {
  1482.         if ($this->punishBlameConfigs->removeElement($punishBlameConfig)) {
  1483.             // set the owning side to null (unless already changed)
  1484.             if ($punishBlameConfig->getYear() === $this) {
  1485.                 $punishBlameConfig->setYear(null);
  1486.             }
  1487.         }
  1488.         return $this;
  1489.     }
  1490.     /**
  1491.      * @return Collection<int, PunishExclusionConfig>
  1492.      */
  1493.     public function getPunishExclusionConfigs(): Collection
  1494.     {
  1495.         return $this->punishExclusionConfigs;
  1496.     }
  1497.     public function addPunishExclusionConfig(PunishExclusionConfig $punishExclusionConfig): static
  1498.     {
  1499.         if (!$this->punishExclusionConfigs->contains($punishExclusionConfig)) {
  1500.             $this->punishExclusionConfigs->add($punishExclusionConfig);
  1501.             $punishExclusionConfig->setYear($this);
  1502.         }
  1503.         return $this;
  1504.     }
  1505.     public function removePunishExclusionConfig(PunishExclusionConfig $punishExclusionConfig): static
  1506.     {
  1507.         if ($this->punishExclusionConfigs->removeElement($punishExclusionConfig)) {
  1508.             // set the owning side to null (unless already changed)
  1509.             if ($punishExclusionConfig->getYear() === $this) {
  1510.                 $punishExclusionConfig->setYear(null);
  1511.             }
  1512.         }
  1513.         return $this;
  1514.     }
  1515.     public function getNameEn(): ?string
  1516.     {
  1517.         return $this->nameEn;
  1518.     }
  1519.     public function setNameEn(string $nameEn): static
  1520.     {
  1521.         $this->nameEn $nameEn;
  1522.         return $this;
  1523.     }
  1524.     /**
  1525.      * @return Collection<int, SchoolYearInfos>
  1526.      */
  1527.     public function getSchoolYearInfos(): Collection
  1528.     {
  1529.         return $this->schoolYearInfos;
  1530.     }
  1531.     public function addSchoolYearInfo(SchoolYearInfos $schoolYearInfo): static
  1532.     {
  1533.         if (!$this->schoolYearInfos->contains($schoolYearInfo)) {
  1534.             $this->schoolYearInfos->add($schoolYearInfo);
  1535.             $schoolYearInfo->setYear($this);
  1536.         }
  1537.         return $this;
  1538.     }
  1539.     public function removeSchoolYearInfo(SchoolYearInfos $schoolYearInfo): static
  1540.     {
  1541.         if ($this->schoolYearInfos->removeElement($schoolYearInfo)) {
  1542.             // set the owning side to null (unless already changed)
  1543.             if ($schoolYearInfo->getYear() === $this) {
  1544.                 $schoolYearInfo->setYear(null);
  1545.             }
  1546.         }
  1547.         return $this;
  1548.     }
  1549.     /**
  1550.      * @return Collection<int, Blame>
  1551.      */
  1552.     public function getBlames(): Collection
  1553.     {
  1554.         return $this->blames;
  1555.     }
  1556.     public function addBlame(Blame $blame): static
  1557.     {
  1558.         if (!$this->blames->contains($blame)) {
  1559.             $this->blames->add($blame);
  1560.             $blame->setYear($this);
  1561.         }
  1562.         return $this;
  1563.     }
  1564.     public function removeBlame(Blame $blame): static
  1565.     {
  1566.         if ($this->blames->removeElement($blame)) {
  1567.             // set the owning side to null (unless already changed)
  1568.             if ($blame->getYear() === $this) {
  1569.                 $blame->setYear(null);
  1570.             }
  1571.         }
  1572.         return $this;
  1573.     }
  1574.     /**
  1575.      * @return Collection<int, Warning>
  1576.      */
  1577.     public function getWarnings(): Collection
  1578.     {
  1579.         return $this->warnings;
  1580.     }
  1581.     public function addWarning(Warning $warning): static
  1582.     {
  1583.         if (!$this->warnings->contains($warning)) {
  1584.             $this->warnings->add($warning);
  1585.             $warning->setYear($this);
  1586.         }
  1587.         return $this;
  1588.     }
  1589.     public function removeWarning(Warning $warning): static
  1590.     {
  1591.         if ($this->warnings->removeElement($warning)) {
  1592.             // set the owning side to null (unless already changed)
  1593.             if ($warning->getYear() === $this) {
  1594.                 $warning->setYear(null);
  1595.             }
  1596.         }
  1597.         return $this;
  1598.     }
  1599.     /**
  1600.      * @return Collection<int, Retained>
  1601.      */
  1602.     public function getRetaineds(): Collection
  1603.     {
  1604.         return $this->retaineds;
  1605.     }
  1606.     public function addRetained(Retained $retained): static
  1607.     {
  1608.         if (!$this->retaineds->contains($retained)) {
  1609.             $this->retaineds->add($retained);
  1610.             $retained->setYear($this);
  1611.         }
  1612.         return $this;
  1613.     }
  1614.     public function removeRetained(Retained $retained): static
  1615.     {
  1616.         if ($this->retaineds->removeElement($retained)) {
  1617.             // set the owning side to null (unless already changed)
  1618.             if ($retained->getYear() === $this) {
  1619.                 $retained->setYear(null);
  1620.             }
  1621.         }
  1622.         return $this;
  1623.     }
  1624.     /**
  1625.      * @return Collection<int, HonnorTableLimitMoy>
  1626.      */
  1627.     public function getHonnorTableLimitMoys(): Collection
  1628.     {
  1629.         return $this->honnorTableLimitMoys;
  1630.     }
  1631.     public function addHonnorTableLimitMoy(HonnorTableLimitMoy $honnorTableLimitMoy): static
  1632.     {
  1633.         if (!$this->honnorTableLimitMoys->contains($honnorTableLimitMoy)) {
  1634.             $this->honnorTableLimitMoys->add($honnorTableLimitMoy);
  1635.             $honnorTableLimitMoy->setYear($this);
  1636.         }
  1637.         return $this;
  1638.     }
  1639.     public function removeHonnorTableLimitMoy(HonnorTableLimitMoy $honnorTableLimitMoy): static
  1640.     {
  1641.         if ($this->honnorTableLimitMoys->removeElement($honnorTableLimitMoy)) {
  1642.             // set the owning side to null (unless already changed)
  1643.             if ($honnorTableLimitMoy->getYear() === $this) {
  1644.                 $honnorTableLimitMoy->setYear(null);
  1645.             }
  1646.         }
  1647.         return $this;
  1648.     }
  1649.     /**
  1650.      * @return Collection<int, News>
  1651.      */
  1652.     public function getNews(): Collection
  1653.     {
  1654.         return $this->news;
  1655.     }
  1656.     public function addNews(News $news): static
  1657.     {
  1658.         if (!$this->news->contains($news)) {
  1659.             $this->news->add($news);
  1660.             $news->setYear($this);
  1661.         }
  1662.         return $this;
  1663.     }
  1664.     public function removeNews(News $news): static
  1665.     {
  1666.         if ($this->news->removeElement($news)) {
  1667.             // set the owning side to null (unless already changed)
  1668.             if ($news->getYear() === $this) {
  1669.                 $news->setYear(null);
  1670.             }
  1671.         }
  1672.         return $this;
  1673.     }
  1674.     /**
  1675.      * @return Collection<int, Event>
  1676.      */
  1677.     public function getEvents(): Collection
  1678.     {
  1679.         return $this->events;
  1680.     }
  1681.     public function addEvent(Event $event): static
  1682.     {
  1683.         if (!$this->events->contains($event)) {
  1684.             $this->events->add($event);
  1685.             $event->setYear($this);
  1686.         }
  1687.         return $this;
  1688.     }
  1689.     public function removeEvent(Event $event): static
  1690.     {
  1691.         if ($this->events->removeElement($event)) {
  1692.             // set the owning side to null (unless already changed)
  1693.             if ($event->getYear() === $this) {
  1694.                 $event->setYear(null);
  1695.             }
  1696.         }
  1697.         return $this;
  1698.     }
  1699.     /**
  1700.      * @return Collection<int, AdmissionLimit>
  1701.      */
  1702.     public function getAdmissionLimits(): Collection
  1703.     {
  1704.         return $this->admissionLimits;
  1705.     }
  1706.     public function addAdmissionLimit(AdmissionLimit $admissionLimit): static
  1707.     {
  1708.         if (!$this->admissionLimits->contains($admissionLimit)) {
  1709.             $this->admissionLimits->add($admissionLimit);
  1710.             $admissionLimit->setYear($this);
  1711.         }
  1712.         return $this;
  1713.     }
  1714.     public function removeAdmissionLimit(AdmissionLimit $admissionLimit): static
  1715.     {
  1716.         if ($this->admissionLimits->removeElement($admissionLimit)) {
  1717.             // set the owning side to null (unless already changed)
  1718.             if ($admissionLimit->getYear() === $this) {
  1719.                 $admissionLimit->setYear(null);
  1720.             }
  1721.         }
  1722.         return $this;
  1723.     }
  1724.     public function getAgendaTimeConvertion(): ?AgendaTimeConvertion
  1725.     {
  1726.         return $this->agendaTimeConvertion;
  1727.     }
  1728.     public function setAgendaTimeConvertion(AgendaTimeConvertion $agendaTimeConvertion): static
  1729.     {
  1730.         // set the owning side of the relation if necessary
  1731.         if ($agendaTimeConvertion->getYear() !== $this) {
  1732.             $agendaTimeConvertion->setYear($this);
  1733.         }
  1734.         $this->agendaTimeConvertion $agendaTimeConvertion;
  1735.         return $this;
  1736.     }
  1737.     /**
  1738.      * @return Collection<int, ExamWeek>
  1739.      */
  1740.     public function getExamWeeks(): Collection
  1741.     {
  1742.         return $this->examWeeks;
  1743.     }
  1744.     public function addExamWeek(ExamWeek $examWeek): static
  1745.     {
  1746.         if (!$this->examWeeks->contains($examWeek)) {
  1747.             $this->examWeeks->add($examWeek);
  1748.             $examWeek->setYear($this);
  1749.         }
  1750.         return $this;
  1751.     }
  1752.     public function removeExamWeek(ExamWeek $examWeek): static
  1753.     {
  1754.         if ($this->examWeeks->removeElement($examWeek)) {
  1755.             // set the owning side to null (unless already changed)
  1756.             if ($examWeek->getYear() === $this) {
  1757.                 $examWeek->setYear(null);
  1758.             }
  1759.         }
  1760.         return $this;
  1761.     }
  1762.     /**
  1763.      * @return Collection<int, Competence>
  1764.      */
  1765.     public function getCompetences(): Collection
  1766.     {
  1767.         return $this->competences;
  1768.     }
  1769.     public function addCompetence(Competence $competence): static
  1770.     {
  1771.         if (!$this->competences->contains($competence)) {
  1772.             $this->competences->add($competence);
  1773.             $competence->setYear($this);
  1774.         }
  1775.         return $this;
  1776.     }
  1777.     public function removeCompetence(Competence $competence): static
  1778.     {
  1779.         if ($this->competences->removeElement($competence)) {
  1780.             // set the owning side to null (unless already changed)
  1781.             if ($competence->getYear() === $this) {
  1782.                 $competence->setYear(null);
  1783.             }
  1784.         }
  1785.         return $this;
  1786.     }
  1787.     /**
  1788.      * @return Collection<int, WeekSubjectGoal>
  1789.      */
  1790.     public function getWeekSubjectGoals(): Collection
  1791.     {
  1792.         return $this->weekSubjectGoals;
  1793.     }
  1794.     public function addWeekSubjectGoal(WeekSubjectGoal $weekSubjectGoal): static
  1795.     {
  1796.         if (!$this->weekSubjectGoals->contains($weekSubjectGoal)) {
  1797.             $this->weekSubjectGoals->add($weekSubjectGoal);
  1798.             $weekSubjectGoal->setYear($this);
  1799.         }
  1800.         return $this;
  1801.     }
  1802.     public function removeWeekSubjectGoal(WeekSubjectGoal $weekSubjectGoal): static
  1803.     {
  1804.         if ($this->weekSubjectGoals->removeElement($weekSubjectGoal)) {
  1805.             // set the owning side to null (unless already changed)
  1806.             if ($weekSubjectGoal->getYear() === $this) {
  1807.                 $weekSubjectGoal->setYear(null);
  1808.             }
  1809.         }
  1810.         return $this;
  1811.     }
  1812.     /**
  1813.      * @return Collection<int, ProfSchoolPlanner>
  1814.      */
  1815.     public function getProfSchoolPlanners(): Collection
  1816.     {
  1817.         return $this->profSchoolPlanners;
  1818.     }
  1819.     public function addProfSchoolPlanner(ProfSchoolPlanner $profSchoolPlanner): static
  1820.     {
  1821.         if (!$this->profSchoolPlanners->contains($profSchoolPlanner)) {
  1822.             $this->profSchoolPlanners->add($profSchoolPlanner);
  1823.             $profSchoolPlanner->setYear($this);
  1824.         }
  1825.         return $this;
  1826.     }
  1827.     public function removeProfSchoolPlanner(ProfSchoolPlanner $profSchoolPlanner): static
  1828.     {
  1829.         if ($this->profSchoolPlanners->removeElement($profSchoolPlanner)) {
  1830.             // set the owning side to null (unless already changed)
  1831.             if ($profSchoolPlanner->getYear() === $this) {
  1832.                 $profSchoolPlanner->setYear(null);
  1833.             }
  1834.         }
  1835.         return $this;
  1836.     }
  1837.     /**
  1838.      * @return Collection<int, ProfTime>
  1839.      */
  1840.     public function getProfTimes(): Collection
  1841.     {
  1842.         return $this->profTimes;
  1843.     }
  1844.     public function addProfTime(ProfTime $profTime): static
  1845.     {
  1846.         if (!$this->profTimes->contains($profTime)) {
  1847.             $this->profTimes->add($profTime);
  1848.             $profTime->setYear($this);
  1849.         }
  1850.         return $this;
  1851.     }
  1852.     public function removeProfTime(ProfTime $profTime): static
  1853.     {
  1854.         if ($this->profTimes->removeElement($profTime)) {
  1855.             // set the owning side to null (unless already changed)
  1856.             if ($profTime->getYear() === $this) {
  1857.                 $profTime->setYear(null);
  1858.             }
  1859.         }
  1860.         return $this;
  1861.     }
  1862.     /**
  1863.      * @return Collection<int, SchoolPlannerType>
  1864.      */
  1865.     public function getSchoolPlannerTypes(): Collection
  1866.     {
  1867.         return $this->schoolPlannerTypes;
  1868.     }
  1869.     public function addSchoolPlannerType(SchoolPlannerType $schoolPlannerType): static
  1870.     {
  1871.         if (!$this->schoolPlannerTypes->contains($schoolPlannerType)) {
  1872.             $this->schoolPlannerTypes->add($schoolPlannerType);
  1873.             $schoolPlannerType->setYear($this);
  1874.         }
  1875.         return $this;
  1876.     }
  1877.     public function removeSchoolPlannerType(SchoolPlannerType $schoolPlannerType): static
  1878.     {
  1879.         if ($this->schoolPlannerTypes->removeElement($schoolPlannerType)) {
  1880.             // set the owning side to null (unless already changed)
  1881.             if ($schoolPlannerType->getYear() === $this) {
  1882.                 $schoolPlannerType->setYear(null);
  1883.             }
  1884.         }
  1885.         return $this;
  1886.     }
  1887.     /**
  1888.      * @return Collection<int, AgendaElement>
  1889.      */
  1890.     public function getAgendaElements(): Collection
  1891.     {
  1892.         return $this->agendaElements;
  1893.     }
  1894.     public function addAgendaElement(AgendaElement $agendaElement): static
  1895.     {
  1896.         if (!$this->agendaElements->contains($agendaElement)) {
  1897.             $this->agendaElements->add($agendaElement);
  1898.             $agendaElement->setYear($this);
  1899.         }
  1900.         return $this;
  1901.     }
  1902.     public function removeAgendaElement(AgendaElement $agendaElement): static
  1903.     {
  1904.         if ($this->agendaElements->removeElement($agendaElement)) {
  1905.             // set the owning side to null (unless already changed)
  1906.             if ($agendaElement->getYear() === $this) {
  1907.                 $agendaElement->setYear(null);
  1908.             }
  1909.         }
  1910.         return $this;
  1911.     }
  1912.     /**
  1913.      * @return Collection<int, GlobalSchoolBreak>
  1914.      */
  1915.     public function getGlobalSchoolBreaks(): Collection
  1916.     {
  1917.         return $this->globalSchoolBreaks;
  1918.     }
  1919.     public function addGlobalSchoolBreak(GlobalSchoolBreak $globalSchoolBreak): static
  1920.     {
  1921.         if (!$this->globalSchoolBreaks->contains($globalSchoolBreak)) {
  1922.             $this->globalSchoolBreaks->add($globalSchoolBreak);
  1923.             $globalSchoolBreak->setYear($this);
  1924.         }
  1925.         return $this;
  1926.     }
  1927.     public function removeGlobalSchoolBreak(GlobalSchoolBreak $globalSchoolBreak): static
  1928.     {
  1929.         if ($this->globalSchoolBreaks->removeElement($globalSchoolBreak)) {
  1930.             // set the owning side to null (unless already changed)
  1931.             if ($globalSchoolBreak->getYear() === $this) {
  1932.                 $globalSchoolBreak->setYear(null);
  1933.             }
  1934.         }
  1935.         return $this;
  1936.     }
  1937.     /**
  1938.      * @return Collection<int, TeacherAbsence>
  1939.      */
  1940.     public function getTeacherAbsences(): Collection
  1941.     {
  1942.         return $this->teacherAbsences;
  1943.     }
  1944.     public function addTeacherAbsence(TeacherAbsence $teacherAbsence): static
  1945.     {
  1946.         if (!$this->teacherAbsences->contains($teacherAbsence)) {
  1947.             $this->teacherAbsences->add($teacherAbsence);
  1948.             $teacherAbsence->setYear($this);
  1949.         }
  1950.         return $this;
  1951.     }
  1952.     public function removeTeacherAbsence(TeacherAbsence $teacherAbsence): static
  1953.     {
  1954.         if ($this->teacherAbsences->removeElement($teacherAbsence)) {
  1955.             // set the owning side to null (unless already changed)
  1956.             if ($teacherAbsence->getYear() === $this) {
  1957.                 $teacherAbsence->setYear(null);
  1958.             }
  1959.         }
  1960.         return $this;
  1961.     }
  1962.     /**
  1963.      * @return Collection<int, AttendanceMissed>
  1964.      */
  1965.     public function getAttendanceMisseds(): Collection
  1966.     {
  1967.         return $this->attendanceMisseds;
  1968.     }
  1969.     public function addAttendanceMissed(AttendanceMissed $attendanceMissed): static
  1970.     {
  1971.         if (!$this->attendanceMisseds->contains($attendanceMissed)) {
  1972.             $this->attendanceMisseds->add($attendanceMissed);
  1973.             $attendanceMissed->setYear($this);
  1974.         }
  1975.         return $this;
  1976.     }
  1977.     public function removeAttendanceMissed(AttendanceMissed $attendanceMissed): static
  1978.     {
  1979.         if ($this->attendanceMisseds->removeElement($attendanceMissed)) {
  1980.             // set the owning side to null (unless already changed)
  1981.             if ($attendanceMissed->getYear() === $this) {
  1982.                 $attendanceMissed->setYear(null);
  1983.             }
  1984.         }
  1985.         return $this;
  1986.     }
  1987.     /**
  1988.      * @return Collection<int, GeneralBreak>
  1989.      */
  1990.     public function getGeneralBreaks(): Collection
  1991.     {
  1992.         return $this->generalBreaks;
  1993.     }
  1994.     public function addGeneralBreak(GeneralBreak $generalBreak): static
  1995.     {
  1996.         if (!$this->generalBreaks->contains($generalBreak)) {
  1997.             $this->generalBreaks->add($generalBreak);
  1998.             $generalBreak->setYear($this);
  1999.         }
  2000.         return $this;
  2001.     }
  2002.     public function removeGeneralBreak(GeneralBreak $generalBreak): static
  2003.     {
  2004.         if ($this->generalBreaks->removeElement($generalBreak)) {
  2005.             // set the owning side to null (unless already changed)
  2006.             if ($generalBreak->getYear() === $this) {
  2007.                 $generalBreak->setYear(null);
  2008.             }
  2009.         }
  2010.         return $this;
  2011.     }
  2012.     public function getLevel(): ?int
  2013.     {
  2014.         return $this->level;
  2015.     }
  2016.     public function setLevel(?int $level): static
  2017.     {
  2018.         $this->level $level;
  2019.         return $this;
  2020.     }
  2021. }