src/Entity/Course.php line 12

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\CourseRepository;
  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(repositoryClassCourseRepository::class)]
  9. class Course
  10. {
  11.     #[ORM\Id]
  12.     #[ORM\GeneratedValue]
  13.     #[ORM\Column(type'integer')]
  14.     private $id;
  15.     #[ORM\ManyToOne(targetEntityClubInfo::class, inversedBy'courses'fetch"EAGER")]
  16.     private $club;
  17.     #[ORM\OneToOne(targetEntityAddress::class, inversedBy'course'cascade: ['persist''remove'])]
  18.     private $address;
  19.     #[ORM\OneToMany(targetEntityPhoto::class, mappedBy'course'cascade: ['persist''remove'])]
  20.     private $photos;
  21.     #[ORM\OneToMany(targetEntityVideo::class, mappedBy'course'cascade: ['persist''remove'])]
  22.     private $videos;
  23.     #[ORM\Column(type'array'nullabletrue)]
  24.     private $logistic = [];
  25.     #[ORM\OneToMany(targetEntityAirport::class, mappedBy'course'cascade: ['persist''remove'], orphanRemovaltrue)]
  26.     private $airports;
  27.     #[ORM\OneToMany(targetEntityBeach::class, mappedBy'course'cascade: ['persist''remove'], orphanRemovaltrue)]
  28.     private $beaches;
  29.     #[ORM\OneToMany(targetEntityStation::class, mappedBy'course'cascade: ['persist''remove'], orphanRemovaltrue)]
  30.     private $stations;
  31.     #[ORM\OneToMany(targetEntityRestaurant::class, mappedBy'course'cascade: ['persist''remove'], orphanRemovaltrue)]
  32.     private $restaurants;
  33.     #[ORM\OneToMany(targetEntityAccommodation::class, mappedBy'course'cascade: ['persist''remove'], orphanRemovaltrue)]
  34.     private $accommodations;
  35.     #[ORM\ManyToOne(targetEntityUser::class, inversedBy'courses')]
  36.     private $owner;
  37.     #[ORM\ManyToMany(targetEntitySport::class, inversedBy'courses')]
  38.     private $sports;
  39.     #[ORM\OneToMany(targetEntityCourseAvailability::class, mappedBy'course'cascade: ['persist''remove'])]
  40.     private $availabilities;
  41.     #[ORM\Column(type'string'length255nullabletrue)]
  42.     private $frequency;
  43.     #[ORM\ManyToMany(targetEntityLanguage::class, inversedBy'courses')]
  44.     private $languages;
  45.     
  46.     #[ORM\OneToMany(targetEntityFeaturedCourse::class, mappedBy'course')]
  47.     private $featureds;
  48.     #[ORM\Column(type'string'length255)]
  49.     private $status;
  50.     #[ORM\Column(type'datetime'nullabletrue)]
  51.     private $createdAt;
  52.     #[ORM\ManyToMany(targetEntityAge::class, inversedBy'courses')]
  53.     private $ages;
  54.     #[ORM\ManyToMany(targetEntityLevel::class, inversedBy'courses')]
  55.     private $levels;
  56.     #[ORM\ManyToMany(targetEntityTrainee::class, mappedBy'favorites')]
  57.     private $traineesFavorites;
  58.     #[ORM\OneToMany(targetEntityTranslatedCourse::class, mappedBy'course'cascade: ['persist''remove'])]
  59.     private $translatedContents;
  60.     #[ORM\Column(type'string'length255)]
  61.     private $token;
  62.     #[ORM\OneToMany(targetEntityBooking::class, mappedBy'course')]
  63.     private $bookings;
  64.     #[ORM\Column(type'string'length255)]
  65.     private $countryCode;
  66.     #[ORM\Column(type'float'nullabletrue)]
  67.     private $latitude;
  68.     #[ORM\Column(type'float'nullabletrue)]
  69.     private $longitude;
  70.     #[ORM\OneToMany(targetEntityCourseViewsStat::class, mappedBy'course'cascade: ['persist''remove'])]
  71.     private $courseViewsStats;
  72.     #[ORM\Column(type'boolean')]
  73.     private $hideClubInfo;
  74.     #[ORM\Column(type'boolean')]
  75.     private $hideCoachInfo;
  76.     #[ORM\Column(type'integer'length255nullabletrue)]
  77.     private $stepSaved;
  78.     #[ORM\ManyToMany(targetEntityCoachInfo::class, inversedBy'courses')]
  79.     private $coachsInfos;
  80.     #[ORM\Column(type'boolean'nullabletrue)]
  81.     private $sendedAlert;
  82.     #[ORM\Column(length255nullabletrue)]
  83.     private ?string $cover null;
  84.     #[ORM\OneToMany(mappedBy'course'targetEntityPriceBundle::class)]
  85.     private Collection $priceBundles;
  86.     private $translateName;
  87.     private $translateDescription;
  88.     private $translatePlanning;
  89.     private $translateOther;
  90.     #[ORM\Column(nullabletrue)]
  91.     private ?bool $visibleToClub true;
  92.     #[ORM\Column(nullabletrue)]
  93.     private ?bool $visibleToCoach true;
  94.     #[ORM\Column(nullabletrue)]
  95.     private ?bool $visibleToOperator true;
  96.     #[ORM\Column(typeTypes::DATETIME_MUTABLEnullabletrue)]
  97.     private ?\DateTimeInterface $publishedAt null;
  98.     #[ORM\Column(typeTypes::DATETIME_MUTABLEnullabletrue)]
  99.     private ?\DateTimeInterface $updatedAt null;
  100.     #[ORM\ManyToOne(inversedBy'associatedCourses')]
  101.     private ?OperatorInfo $operator null;
  102.     #[ORM\OneToMany(mappedBy'course'targetEntityNoteRequest::class)]
  103.     private Collection $noteRequests;
  104.     #[ORM\OneToMany(mappedBy'course'targetEntityNote::class)]
  105.     private Collection $notes;
  106.     public function __construct()
  107.     {
  108.         $this->photos = new ArrayCollection();
  109.         $this->videos = new ArrayCollection();
  110.         $this->airports = new ArrayCollection();
  111.         $this->beaches = new ArrayCollection();
  112.         $this->stations = new ArrayCollection();
  113.         $this->restaurants = new ArrayCollection();
  114.         $this->accommodations = new ArrayCollection();
  115.         $this->sports = new ArrayCollection();
  116.         $this->availabilities = new ArrayCollection();
  117.         $this->languages = new ArrayCollection();
  118.         $this->featureds = new ArrayCollection();
  119.         $this->ages = new ArrayCollection();
  120.         $this->levels = new ArrayCollection();
  121.         $this->traineesFavorites = new ArrayCollection();
  122.         $this->translatedContents = new ArrayCollection();
  123.         $this->bookings = new ArrayCollection();
  124.         $this->courseViewsStats = new ArrayCollection();
  125.         $this->coachsInfos = new ArrayCollection();
  126.         $this->priceBundles = new ArrayCollection();
  127.         $this->noteRequests = new ArrayCollection();
  128.         $this->notes = new ArrayCollection();
  129.     }
  130.     public function getId(): ?int
  131.     {
  132.         return $this->id;
  133.     }
  134.     public function getClub(): ?ClubInfo
  135.     {
  136.         return $this->club;
  137.     }
  138.     public function setClub(?ClubInfo $club): self
  139.     {
  140.         $this->club $club;
  141.         return $this;
  142.     }
  143.     public function getAddress(): ?Address
  144.     {
  145.         return $this->address;
  146.     }
  147.     public function setAddress(?Address $address): self
  148.     {
  149.         $this->address $address;
  150.         return $this;
  151.     }
  152.     /**
  153.      * @return Collection|Photo[]
  154.      */
  155.     public function getPhotos(): Collection
  156.     {
  157.         return $this->photos;
  158.     }
  159.     public function addPhoto(Photo $photo): self
  160.     {
  161.         if (!$this->photos->contains($photo)) {
  162.             $this->photos[] = $photo;
  163.             $photo->setCourse($this);
  164.         }
  165.         return $this;
  166.     }
  167.     public function removePhoto(Photo $photo): self
  168.     {
  169.         if ($this->photos->removeElement($photo)) {
  170.             // set the owning side to null (unless already changed)
  171.             if ($photo->getCourse() === $this) {
  172.                 $photo->setCourse(null);
  173.             }
  174.         }
  175.         return $this;
  176.     }
  177.     /**
  178.      * @return Collection|Video[]
  179.      */
  180.     public function getVideos(): Collection
  181.     {
  182.         return $this->videos;
  183.     }
  184.     public function addVideo(Video $video): self
  185.     {
  186.         if (!$this->videos->contains($video)) {
  187.             $this->videos[] = $video;
  188.             $video->setCourse($this);
  189.         }
  190.         return $this;
  191.     }
  192.     public function removeVideo(Video $video): self
  193.     {
  194.         if ($this->videos->removeElement($video)) {
  195.             // set the owning side to null (unless already changed)
  196.             if ($video->getCourse() === $this) {
  197.                 $video->setCourse(null);
  198.             }
  199.         }
  200.         return $this;
  201.     }
  202.     public function getLogistic(): ?array
  203.     {
  204.         return $this->logistic;
  205.     }
  206.     public function setLogistic(?array $logistic): self
  207.     {
  208.         $this->logistic $logistic;
  209.         return $this;
  210.     }
  211.     /**
  212.      * @return Collection|Airport[]
  213.      */
  214.     public function getAirports(): Collection
  215.     {
  216.         return $this->airports;
  217.     }
  218.     public function addAirport(Airport $airport): self
  219.     {
  220.         if (!$this->airports->contains($airport)) {
  221.             $this->airports[] = $airport;
  222.             $airport->setCourse($this);
  223.         }
  224.         return $this;
  225.     }
  226.     public function removeAirport(Airport $airport): self
  227.     {
  228.         if ($this->airports->removeElement($airport)) {
  229.             // set the owning side to null (unless already changed)
  230.             if ($airport->getCourse() === $this) {
  231.                 $airport->setCourse(null);
  232.             }
  233.         }
  234.         return $this;
  235.     }
  236.     /**
  237.      * @return Collection|Beach[]
  238.      */
  239.     public function getBeaches(): Collection
  240.     {
  241.         return $this->beaches;
  242.     }
  243.     public function addBeach(Beach $beach): self
  244.     {
  245.         if (!$this->beaches->contains($beach)) {
  246.             $this->beaches[] = $beach;
  247.             $beach->setCourse($this);
  248.         }
  249.         return $this;
  250.     }
  251.     public function removeBeach(Beach $beach): self
  252.     {
  253.         if ($this->beaches->removeElement($beach)) {
  254.             // set the owning side to null (unless already changed)
  255.             if ($beach->getCourse() === $this) {
  256.                 $beach->setCourse(null);
  257.             }
  258.         }
  259.         return $this;
  260.     }
  261.     /**
  262.      * @return Collection|Station[]
  263.      */
  264.     public function getStations(): Collection
  265.     {
  266.         return $this->stations;
  267.     }
  268.     public function addStation(Station $station): self
  269.     {
  270.         if (!$this->stations->contains($station)) {
  271.             $this->stations[] = $station;
  272.             $station->setCourse($this);
  273.         }
  274.         return $this;
  275.     }
  276.     public function removeStation(Station $station): self
  277.     {
  278.         if ($this->stations->removeElement($station)) {
  279.             // set the owning side to null (unless already changed)
  280.             if ($station->getCourse() === $this) {
  281.                 $station->setCourse(null);
  282.             }
  283.         }
  284.         return $this;
  285.     }
  286.     /**
  287.      * @return Collection|Restaurant[]
  288.      */
  289.     public function getRestaurants(): Collection
  290.     {
  291.         return $this->restaurants;
  292.     }
  293.     public function addRestaurant(Restaurant $restaurant): self
  294.     {
  295.         if (!$this->restaurants->contains($restaurant)) {
  296.             $this->restaurants[] = $restaurant;
  297.             $restaurant->setCourse($this);
  298.         }
  299.         return $this;
  300.     }
  301.     public function removeRestaurant(Restaurant $restaurant): self
  302.     {
  303.         if ($this->restaurants->removeElement($restaurant)) {
  304.             // set the owning side to null (unless already changed)
  305.             if ($restaurant->getCourse() === $this) {
  306.                 $restaurant->setCourse(null);
  307.             }
  308.         }
  309.         return $this;
  310.     }
  311.     /**
  312.      * @return Collection|Accommodation[]
  313.      */
  314.     public function getAccommodations(): Collection
  315.     {
  316.         return $this->accommodations;
  317.     }
  318.     public function addAccommodation(Accommodation $accommodation): self
  319.     {
  320.         if (!$this->accommodations->contains($accommodation)) {
  321.             $this->accommodations[] = $accommodation;
  322.             $accommodation->setCourse($this);
  323.         }
  324.         return $this;
  325.     }
  326.     public function removeAccommodation(Accommodation $accommodation): self
  327.     {
  328.         if ($this->accommodations->removeElement($accommodation)) {
  329.             // set the owning side to null (unless already changed)
  330.             if ($accommodation->getCourse() === $this) {
  331.                 $accommodation->setCourse(null);
  332.             }
  333.         }
  334.         return $this;
  335.     }
  336.     public function getOwner(): ?User
  337.     {
  338.         return $this->owner;
  339.     }
  340.     public function setOwner(?User $owner): self
  341.     {
  342.         $this->owner $owner;
  343.         return $this;
  344.     }
  345.     /**
  346.      * @return Collection|Sport[]
  347.      */
  348.     public function getSports(): Collection
  349.     {
  350.         return $this->sports;
  351.     }
  352.     public function addSport(Sport $sport): self
  353.     {
  354.         if (!$this->sports->contains($sport)) {
  355.             $this->sports[] = $sport;
  356.         }
  357.         return $this;
  358.     }
  359.     public function removeSport(Sport $sport): self
  360.     {
  361.         $this->sports->removeElement($sport);
  362.         return $this;
  363.     }
  364.     /**
  365.      * @return Collection|CourseAvailability[]
  366.      */
  367.     public function getAvailabilities(): Collection
  368.     {
  369.         return $this->availabilities;
  370.     }
  371.     public function addAvailability(CourseAvailability $availability): self
  372.     {
  373.         if (!$this->availabilities->contains($availability)) {
  374.             $this->availabilities[] = $availability;
  375.             $availability->setCourse($this);
  376.         }
  377.         return $this;
  378.     }
  379.     public function removeAvailability(CourseAvailability $availability): self
  380.     {
  381.         if ($this->availabilities->removeElement($availability)) {
  382.             // set the owning side to null (unless already changed)
  383.             if ($availability->getCourse() === $this) {
  384.                 $availability->setCourse(null);
  385.             }
  386.         }
  387.         return $this;
  388.     }
  389.     public function getFrequency(): ?string
  390.     {
  391.         return $this->frequency;
  392.     }
  393.     public function setFrequency(string $frequency): self
  394.     {
  395.         $this->frequency $frequency;
  396.         return $this;
  397.     }
  398.     /**
  399.      * @return Collection|Language[]
  400.      */
  401.     public function getLanguages(): Collection
  402.     {
  403.         return $this->languages;
  404.     }
  405.     public function addLanguage(Language $language): self
  406.     {
  407.         if (!$this->languages->contains($language)) {
  408.             $this->languages[] = $language;
  409.         }
  410.         return $this;
  411.     }
  412.     public function removeLanguage(Language $language): self
  413.     {
  414.         $this->languages->removeElement($language);
  415.         return $this;
  416.     }
  417.     /**
  418.      * @return Collection|FeaturedCourse[]
  419.      */
  420.     public function getFeatureds(): Collection
  421.     {
  422.         return $this->featureds;
  423.     }
  424.     public function addFeatured(FeaturedCourse $featured): self
  425.     {
  426.         if (!$this->featureds->contains($featured)) {
  427.             $this->featureds[] = $featured;
  428.             $featured->setCourse($this);
  429.         }
  430.         return $this;
  431.     }
  432.     public function removeFeatured(FeaturedCourse $featured): self
  433.     {
  434.         if ($this->featureds->removeElement($featured)) {
  435.             // set the owning side to null (unless already changed)
  436.             if ($featured->getCourse() === $this) {
  437.                 $featured->setCourse(null);
  438.             }
  439.         }
  440.         return $this;
  441.     }
  442.     public function getStatus(): ?string
  443.     {
  444.         return $this->status;
  445.     }
  446.     public function setStatus(string $status): self
  447.     {
  448.         $this->status $status;
  449.         return $this;
  450.     }
  451.     public function getCreatedAt(): ?\DateTimeInterface
  452.     {
  453.         return $this->createdAt;
  454.     }
  455.     public function setCreatedAt(\DateTimeInterface $createdAt): self
  456.     {
  457.         $this->createdAt $createdAt;
  458.         return $this;
  459.     }
  460.     /**
  461.      * @return Collection|Age[]
  462.      */
  463.     public function getAges(): Collection
  464.     {
  465.         return $this->ages;
  466.     }
  467.     public function addAge(Age $age): self
  468.     {
  469.         if (!$this->ages->contains($age)) {
  470.             $this->ages[] = $age;
  471.         }
  472.         return $this;
  473.     }
  474.     public function removeAge(Age $age): self
  475.     {
  476.         $this->ages->removeElement($age);
  477.         return $this;
  478.     }
  479.     /**
  480.      * @return Collection|Level[]
  481.      */
  482.     public function getLevels(): Collection
  483.     {
  484.         return $this->levels;
  485.     }
  486.     public function addLevel(Level $level): self
  487.     {
  488.         if (!$this->levels->contains($level)) {
  489.             $this->levels[] = $level;
  490.         }
  491.         return $this;
  492.     }
  493.     public function removeLevel(Level $level): self
  494.     {
  495.         $this->levels->removeElement($level);
  496.         return $this;
  497.     }
  498.     /**
  499.      * @return Collection|Trainee[]
  500.      */
  501.     public function getTraineesFavorites(): Collection
  502.     {
  503.         return $this->traineesFavorites;
  504.     }
  505.     public function addTraineesFavorite(Trainee $traineesFavorite): self
  506.     {
  507.         if (!$this->traineesFavorites->contains($traineesFavorite)) {
  508.             $this->traineesFavorites[] = $traineesFavorite;
  509.             $traineesFavorite->addFavorite($this);
  510.         }
  511.         return $this;
  512.     }
  513.     public function removeTraineesFavorite(Trainee $traineesFavorite): self
  514.     {
  515.         if ($this->traineesFavorites->removeElement($traineesFavorite)) {
  516.             $traineesFavorite->removeFavorite($this);
  517.         }
  518.         return $this;
  519.     }
  520.     /**
  521.      * @return Collection|TranslatedCourse[]
  522.      */
  523.     public function getTranslatedContents(): Collection
  524.     {
  525.         return $this->translatedContents;
  526.     }
  527.     public function addTranslatedContent(TranslatedCourse $translatedContent): self
  528.     {
  529.         if (!$this->translatedContents->contains($translatedContent)) {
  530.             $this->translatedContents[] = $translatedContent;
  531.             $translatedContent->setCourse($this);
  532.         }
  533.         return $this;
  534.     }
  535.     public function removeTranslatedContent(TranslatedCourse $translatedContent): self
  536.     {
  537.         if ($this->translatedContents->removeElement($translatedContent)) {
  538.             // set the owning side to null (unless already changed)
  539.             if ($translatedContent->getCourse() === $this) {
  540.                 $translatedContent->setCourse(null);
  541.             }
  542.         }
  543.         return $this;
  544.     }
  545.     public function getToken(): ?string
  546.     {
  547.         return $this->token;
  548.     }
  549.     public function setToken(string $token): self
  550.     {
  551.         $this->token $token;
  552.         return $this;
  553.     }
  554.     
  555.     public function getTranslatedContent($local)
  556.     {
  557.         foreach($this->translatedContents as $translatedCourse)
  558.         {
  559.             if($translatedCourse->getLanguage() == $local)
  560.             {
  561.                 return $translatedCourse;
  562.             }
  563.         }
  564.         foreach($this->translatedContents as $translatedCourse)
  565.         {
  566.             if($translatedCourse->getLanguage() == 'en')
  567.             {
  568.                 return $translatedCourse;
  569.             }
  570.         }
  571.         return $this->getTranslatedContents()->first() ?? null;
  572.     }
  573.     /**
  574.      * @return Collection|Booking[]
  575.      */
  576.     public function getBookings(): Collection
  577.     {
  578.         return $this->bookings;
  579.     }
  580.     public function addBooking(Booking $booking): self
  581.     {
  582.         if (!$this->bookings->contains($booking)) {
  583.             $this->bookings[] = $booking;
  584.             $booking->setCourse($this);
  585.         }
  586.         return $this;
  587.     }
  588.     public function removeBooking(Booking $booking): self
  589.     {
  590.         if ($this->bookings->removeElement($booking)) {
  591.             // set the owning side to null (unless already changed)
  592.             if ($booking->getCourse() === $this) {
  593.                 $booking->setCourse(null);
  594.             }
  595.         }
  596.         return $this;
  597.     }
  598.     public function getCountryCode(): ?string
  599.     {
  600.         return $this->countryCode;
  601.     }
  602.     public function setCountryCode(string $countryCode): self
  603.     {
  604.         $this->countryCode $countryCode;
  605.         return $this;
  606.     }
  607.     public function getLatitude(): ?float
  608.     {
  609.         return $this->latitude;
  610.     }
  611.     public function setLatitude(?float $latitude): self
  612.     {
  613.         $this->latitude $latitude;
  614.         return $this;
  615.     }
  616.     public function getLongitude(): ?float
  617.     {
  618.         return $this->longitude;
  619.     }
  620.     public function setLongitude(?float $longitude): self
  621.     {
  622.         $this->longitude $longitude;
  623.         return $this;
  624.     }
  625.     /**
  626.      * @return Collection|CourseViewsStat[]
  627.      */
  628.     public function getCourseViewsStats(): Collection
  629.     {
  630.         return $this->courseViewsStats;
  631.     }
  632.     public function addCourseViewsStat(CourseViewsStat $courseViewsStat): self
  633.     {
  634.         if (!$this->courseViewsStats->contains($courseViewsStat)) {
  635.             $this->courseViewsStats[] = $courseViewsStat;
  636.             $courseViewsStat->setCourse($this);
  637.         }
  638.         return $this;
  639.     }
  640.     public function removeCourseViewsStat(CourseViewsStat $courseViewsStat): self
  641.     {
  642.         if ($this->courseViewsStats->removeElement($courseViewsStat)) {
  643.             // set the owning side to null (unless already changed)
  644.             if ($courseViewsStat->getCourse() === $this) {
  645.                 $courseViewsStat->setCourse(null);
  646.             }
  647.         }
  648.         return $this;
  649.     }
  650.     public function getHideClubInfo(): ?bool
  651.     {
  652.         return $this->hideClubInfo;
  653.     }
  654.     public function setHideClubInfo(bool $hideClubInfo): self
  655.     {
  656.         $this->hideClubInfo $hideClubInfo;
  657.         return $this;
  658.     }
  659.     public function getHideCoachInfo(): ?bool
  660.     {
  661.         return $this->hideCoachInfo;
  662.     }
  663.     public function setHideCoachInfo(bool $hideCoachInfo): self
  664.     {
  665.         $this->hideCoachInfo $hideCoachInfo;
  666.         return $this;
  667.     }
  668.     public function getStepSaved(): ?int
  669.     {
  670.         return $this->stepSaved;
  671.     }
  672.     public function setStepSaved(?int $stepSaved): self
  673.     {
  674.         $this->stepSaved $stepSaved;
  675.         return $this;
  676.     }
  677.     /**
  678.      * @return Collection<int, CoachInfo>
  679.      */
  680.     public function getCoachsInfos(): Collection
  681.     {
  682.         return $this->coachsInfos;
  683.     }
  684.     public function addCoachsInfo(CoachInfo $coachsInfo): self
  685.     {
  686.         if (!$this->coachsInfos->contains($coachsInfo)) {
  687.             $this->coachsInfos[] = $coachsInfo;
  688.         }
  689.         return $this;
  690.     }
  691.     public function removeCoachsInfo(CoachInfo $coachsInfo): self
  692.     {
  693.         $this->coachsInfos->removeElement($coachsInfo);
  694.         return $this;
  695.     }
  696.     public function getSendedAlert(): ?bool
  697.     {
  698.         return $this->sendedAlert;
  699.     }
  700.     public function setSendedAlert(?bool $sendedAlert): self
  701.     {
  702.         $this->sendedAlert $sendedAlert;
  703.         return $this;
  704.     }
  705.     public function getCover()
  706.     {
  707.         return $this->cover;
  708.     }
  709.     public function setCover($cover): static
  710.     {
  711.         $this->cover $cover;
  712.         return $this;
  713.     }
  714.     /**
  715.      * @return Collection<int, PriceBundle>
  716.      */
  717.     public function getPriceBundles(): Collection
  718.     {
  719.         return $this->priceBundles;
  720.     }
  721.     public function addPriceBundle(PriceBundle $priceBundle): static
  722.     {
  723.         if (!$this->priceBundles->contains($priceBundle)) {
  724.             $this->priceBundles->add($priceBundle);
  725.             $priceBundle->setCourse($this);
  726.         }
  727.         return $this;
  728.     }
  729.     public function removePriceBundle(PriceBundle $priceBundle): static
  730.     {
  731.         if ($this->priceBundles->removeElement($priceBundle)) {
  732.             // set the owning side to null (unless already changed)
  733.             if ($priceBundle->getCourse() === $this) {
  734.                 $priceBundle->setCourse(null);
  735.             }
  736.         }
  737.         return $this;
  738.     }
  739.     /**
  740.      * Get the value of translateName
  741.      */ 
  742.     public function getTranslateName()
  743.     {
  744.         return $this->translateName;
  745.     }
  746.     /**
  747.      * Set the value of translateName
  748.      *
  749.      * @return  self
  750.      */ 
  751.     public function setTranslateName($translateName)
  752.     {
  753.         $this->translateName $translateName;
  754.         return $this;
  755.     }
  756.     /**
  757.      * Get the value of translateDescription
  758.      */ 
  759.     public function getTranslateDescription()
  760.     {
  761.         return $this->translateDescription;
  762.     }
  763.     /**
  764.      * Set the value of translateDescription
  765.      *
  766.      * @return  self
  767.      */ 
  768.     public function setTranslateDescription($translateDescription)
  769.     {
  770.         $this->translateDescription $translateDescription;
  771.         return $this;
  772.     }
  773.     /**
  774.      * Get the value of translatePlanning
  775.      */ 
  776.     public function getTranslatePlanning()
  777.     {
  778.         return $this->translatePlanning;
  779.     }
  780.     /**
  781.      * Set the value of translatePlanning
  782.      *
  783.      * @return  self
  784.      */ 
  785.     public function setTranslatePlanning($translatePlanning)
  786.     {
  787.         $this->translatePlanning $translatePlanning;
  788.         return $this;
  789.     }
  790.     /**
  791.      * Get the value of translateOther
  792.      */ 
  793.     public function getTranslateOther()
  794.     {
  795.         return $this->translateOther;
  796.     }
  797.     /**
  798.      * Set the value of translateOther
  799.      *
  800.      * @return  self
  801.      */ 
  802.     public function setTranslateOther($translateOther)
  803.     {
  804.         $this->translateOther $translateOther;
  805.         return $this;
  806.     }
  807.     public function isVisibleToClub(): ?bool
  808.     {
  809.         return $this->visibleToClub;
  810.     }
  811.     public function setVisibleToClub(?bool $visibleToClub): static
  812.     {
  813.         $this->visibleToClub $visibleToClub;
  814.         return $this;
  815.     }
  816.     public function isVisibleToCoach(): ?bool
  817.     {
  818.         return $this->visibleToCoach;
  819.     }
  820.     public function setVisibleToCoach(?bool $visibleToCoach): static
  821.     {
  822.         $this->visibleToCoach $visibleToCoach;
  823.         return $this;
  824.     }
  825.     public function isVisibleToOperator(): ?bool
  826.     {
  827.         return $this->visibleToOperator;
  828.     }
  829.     public function setVisibleToOperator(?bool $visibleToOperator): static
  830.     {
  831.         $this->visibleToOperator $visibleToOperator;
  832.         return $this;
  833.     }
  834.     public function getPublishedAt(): ?\DateTimeInterface
  835.     {
  836.         return $this->publishedAt;
  837.     }
  838.     public function setPublishedAt(?\DateTimeInterface $publishedAt): static
  839.     {
  840.         $this->publishedAt $publishedAt;
  841.         return $this;
  842.     }
  843.     public function getUpdatedAt(): ?\DateTimeInterface
  844.     {
  845.         return $this->updatedAt;
  846.     }
  847.     public function setUpdatedAt(?\DateTimeInterface $updatedAt): static
  848.     {
  849.         $this->updatedAt $updatedAt;
  850.         return $this;
  851.     }
  852.     public function getOperator(): ?OperatorInfo
  853.     {
  854.         return $this->operator;
  855.     }
  856.     public function setOperator(?OperatorInfo $operator): static
  857.     {
  858.         $this->operator $operator;
  859.         return $this;
  860.     }
  861.     /**
  862.      * @return Collection<int, NoteRequest>
  863.      */
  864.     public function getNoteRequests(): Collection
  865.     {
  866.         return $this->noteRequests;
  867.     }
  868.     public function addNoteRequest(NoteRequest $noteRequest): static
  869.     {
  870.         if (!$this->noteRequests->contains($noteRequest)) {
  871.             $this->noteRequests->add($noteRequest);
  872.             $noteRequest->setCourse($this);
  873.         }
  874.         return $this;
  875.     }
  876.     public function removeNoteRequest(NoteRequest $noteRequest): static
  877.     {
  878.         if ($this->noteRequests->removeElement($noteRequest)) {
  879.             // set the owning side to null (unless already changed)
  880.             if ($noteRequest->getCourse() === $this) {
  881.                 $noteRequest->setCourse(null);
  882.             }
  883.         }
  884.         return $this;
  885.     }
  886.     /**
  887.      * @return Collection<int, Note>
  888.      */
  889.     public function getNotes(): Collection
  890.     {
  891.         return $this->notes;
  892.     }
  893.     public function addNote(Note $note): static
  894.     {
  895.         if (!$this->notes->contains($note)) {
  896.             $this->notes->add($note);
  897.             $note->setCourse($this);
  898.         }
  899.         return $this;
  900.     }
  901.     public function removeNote(Note $note): static
  902.     {
  903.         if ($this->notes->removeElement($note)) {
  904.             // set the owning side to null (unless already changed)
  905.             if ($note->getCourse() === $this) {
  906.                 $note->setCourse(null);
  907.             }
  908.         }
  909.         return $this;
  910.     }
  911. }