src/Entity/Image.php line 9
<?php
namespace App\Entity;
use App\Repository\ImageRepository;
use Doctrine\ORM\Mapping as ORM;
#[ORM\Entity(repositoryClass: ImageRepository::class)]
class Image
{
#[ORM\Id]
#[ORM\GeneratedValue]
#[ORM\Column(type: 'integer')]
private $id;
#[ORM\Column(type: 'string', length: 255, nullable: true)]
private $path;
#[ORM\ManyToOne(targetEntity: Gallery::class, inversedBy: 'images')]
private $gallery;
public function getId(): ?int
{
return $this->id;
}
public function getPath(): ?string
{
return $this->path;
}
public function setPath(?string $path): self
{
$this->path = $path;
return $this;
}
public function getGallery(): ?Gallery
{
return $this->gallery;
}
public function setGallery(?Gallery $gallery): self
{
$this->gallery = $gallery;
return $this;
}
}