<?phpnamespace App\Entity;use App\Repository\PolicyRepository;use Doctrine\ORM\Mapping as ORM;use DateTimeImmutable;/** * @ORM\Entity(repositoryClass=PolicyRepository::class) */class Policy{ /** * @ORM\Id * @ORM\GeneratedValue * @ORM\Column(type="integer") */ private $id; /** * @ORM\Column(type="string", length=255) */ private $title; /** * @ORM\Column(type="text") */ private $content; /** * @ORM\Column(type="string", length=32, options={"default":"v1.0"}) */ private string $version = 'v1.0'; /** * @ORM\Column(type="datetime_immutable") */ private DateTimeImmutable $createdAt; /** * @ORM\Column(type="datetime_immutable", nullable=true) */ private ?DateTimeImmutable $updatedAt = null; public function __construct() { $this->createdAt = new DateTimeImmutable(); } public function getId(): ?int { return $this->id; } public function getTitle(): ?string { return $this->title; } public function setTitle(string $title): self { $this->title = $title; return $this; } public function getContent(): ?string { return $this->content; } public function setContent(string $content): self { $this->content = $content; return $this; } public function getVersion(): string { return $this->version; } public function setVersion(string $version): self { $this->version = $version; return $this; } public function getCreatedAt(): DateTimeImmutable { return $this->createdAt; } public function setCreatedAt(DateTimeImmutable $createdAt): self { $this->createdAt = $createdAt; return $this; } public function getUpdatedAt(): ?DateTimeImmutable { return $this->updatedAt; } public function setUpdatedAt(?DateTimeImmutable $updatedAt): self { $this->updatedAt = $updatedAt; return $this; }}