src/Entity/CoupDeProjecteur.php line 11

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\CoupDeProjecteurRepository;
  4. use Doctrine\ORM\Mapping as ORM;
  5. use Symfony\Component\Validator\Constraints as Assert;
  6. #[ORM\Entity(repositoryClass:CoupDeProjecteurRepository::class)]
  7. class CoupDeProjecteur
  8. {
  9.     #[ORM\Id]
  10.     #[ORM\GeneratedValue(strategy:'AUTO')]
  11.     #[ORM\Column(type:'integer'unique:true )]
  12.     private $id;
  13.     #[ORM\Column(type:'string'nullable:truelength:255)]
  14.     private $nom;
  15.     #[ORM\Column(type:'text'nullable:true)]
  16.     private $description;
  17.     #[ORM\Column(name:'photo',type:'string'length:5000)]
  18.     #[Assert\File(maxSize:"5000k"mimeTypes:['image/jpeg''image/jpg''image/png''image/GIF'])]
  19.     protected $photo;
  20.     #[ORM\Column(length:255type:'string'nullable:true)]
  21.     private $video;
  22.     #[ORM\Column(length:255type:'string'nullable:true)]
  23.     private $lien;
  24.     #[ORM\Column(type:'date'nullable:true)]
  25.     private $date;
  26.     public function getId(): ?int
  27.     {
  28.         return $this->id;
  29.     }
  30.     public function getNom(): ?string
  31.     {
  32.         return $this->nom;
  33.     }
  34.     public function setNom(?string $nom): self
  35.     {
  36.         $this->nom $nom;
  37.         return $this;
  38.     }
  39.     public function getDescription(): ?string
  40.     {
  41.         return $this->description;
  42.     }
  43.     public function setDescription(?string $description): self
  44.     {
  45.         $this->description $description;
  46.         return $this;
  47.     }
  48.     /**
  49.      * @return mixed
  50.      */
  51.     public function getPhoto()
  52.     {
  53.         return $this->photo;
  54.     }
  55.     /**
  56.      * @param mixed $photo
  57.      */
  58.     public function setPhoto($photo): void
  59.     {
  60.         $this->photo $photo;
  61.     }
  62.     public function getVideo(): ?string
  63.     {
  64.         return $this->video;
  65.     }
  66.     public function setVideo(?string $video): self
  67.     {
  68.         $this->video $video;
  69.         return $this;
  70.     }
  71.     public function getLien(): ?string
  72.     {
  73.         return $this->lien;
  74.     }
  75.     public function setLien(?string $lien): self
  76.     {
  77.         $this->lien $lien;
  78.         return $this;
  79.     }
  80.     public function getDate(): ?\DateTimeInterface
  81.     {
  82.         return $this->date;
  83.     }
  84.     public function setDate(?\DateTimeInterface $date): self
  85.     {
  86.         $this->date $date;
  87.         return $this;
  88.     }
  89. }