src/Entity/News.php line 12
<?php
declare(strict_types=1);
namespace App\Entity;
use App\Repository\NewsRepository;
use Doctrine\DBAL\Types\Types;
use Doctrine\ORM\Mapping as ORM;
#[ORM\Entity(repositoryClass: NewsRepository::class)]
class News
{
final public const RESOURCE_KEY = 'news';
#[ORM\Id]
#[ORM\GeneratedValue]
#[ORM\Column(type: Types::INTEGER)]
private ?int $id = null;
#[ORM\Column(type: Types::STRING, length: 255, nullable: true)]
private ?string $title = null;
/*
* News-Gird description has no limit (max 4.294.967.292)
*/
#[ORM\Column(type: Types::TEXT, nullable: false)]
private string $description;
#[ORM\Column(type: Types::STRING, length: 255, nullable: true)]
private ?string $source = null;
#[ORM\Column(type: Types::STRING, length: 255, nullable: true)]
private ?string $date = null;
#[ORM\Column(type: Types::STRING, length: 255, nullable: true)]
private ?string $image = null;
#[ORM\Column(type: Types::STRING, length: 255, nullable: true)]
private ?string $url = null;
#[ORM\Column(type: Types::STRING, length: 255, nullable: true)]
private ?string $tags = null;
public function getId(): ?int
{
return $this->id;
}
public function getTitle(): ?string
{
return $this->title;
}
public function setTitle(string $title): void
{
$this->title = $title;
}
public function getDescription(): ?string
{
return $this->description;
}
public function setDescription(string $description): void
{
$this->description = $description;
}
public function getSource(): ?string
{
return $this->source;
}
public function setSource(string $source): void
{
$this->source = $source;
}
public function getDate(): ?string
{
return $this->date;
}
public function setDate(string $date): void
{
$this->date = $date;
}
public function getImage(): ?string
{
return $this->image;
}
public function setImage(string $image): void
{
$this->image = $image;
}
public function getUrl(): ?string
{
return $this->url;
}
public function setUrl(string $url): void
{
$this->url = $url;
}
/**
* @return string|null
*/
public function getTags(): ?string
{
return $this->tags;
}
/**
* @param string|null $tags
*/
public function setTags(?string $tags): void
{
$this->tags = $tags;
}
}