Linux SRV-16 6.18.44-paas #1 SMP PREEMPT_DYNAMIC Thu Aug 13 10:08:12 UTC 2026 x86_64
/
proc
/
self
/
root
/
srv
/
data
/
trash
/
vhost_www.rec-app.app_1716798588
/
htdocs
/
src
/
Entity
/
//proc/self/root/srv/data/trash/vhost_www.rec-app.app_1716798588/htdocs/src/Entity/Video.php
<?php namespace App\Entity; use App\Repository\VideoRepository; use Doctrine\ORM\Mapping as ORM; use Symfony\Component\HttpFoundation\File\File; use Symfony\Component\Validator\Constraints as Assert; use Vich\UploaderBundle\Mapping\Annotation as Vich; use ApiPlatform\Core\Annotation\ApiResource; /** * @ORM\Entity(repositoryClass=VideoRepository::class) * @Vich\Uploadable * @ApiResource( * ) */ class Video { /** * @ORM\Id * @ORM\GeneratedValue * @ORM\Column(type="integer") */ private $id; /** * NOTE: This is not a mapped field of entity metadata, just a simple property. * * @Vich\UploadableField(mapping="video_file", fileNameProperty="videoName", size="videoSize") * @Assert\File( * maxSize = "1024M", * mimeTypes = {"video/mp4", "video/x-msvideo", "video/x-matroska"}, * mimeTypesMessage = "Please upload a valid video file (mp4, avi, mkv)." * ) * * @var File|null */ private $videoFile; /** * @ORM\Column(type="string") * * @var string|null */ private $videoName; /** * @ORM\Column(type="integer") * * @var int|null */ private $videoSize; /** * @ORM\Column(type="datetime") * * @var \DateTime|null */ private $updatedAt; public function getId(): ?int { return $this->id; } public function setVideoFile(?File $videoFile = null): void { $this->videoFile = $videoFile; if (null !== $videoFile) { $this->updatedAt = new \DateTimeImmutable(); } } public function getVideoFile(): ?File { return $this->videoFile; } public function setVideoName(?string $videoName): void { $this->videoName = $videoName; } public function getVideoName(): ?string { return $this->videoName; } public function setVideoSize(?int $videoSize): void { $this->videoSize = $videoSize; } public function getVideoSize(): ?int { return $this->videoSize; } }