<?php
namespace App\Entity;
use ApiPlatform\Core\Annotation\ApiResource;
use App\Repository\CommentRepository;
use Doctrine\ORM\Mapping as ORM;
use Doctrine\ORM\Mapping\Index;
#[ORM\Entity(repositoryClass: CommentRepository::class)]
#[Index(name: "comment_parent", columns: ["type", "par"])]
#[Index(name: "comment_user", columns: ["user"])]
#[Index(name: "comment_tstamp", columns: ["tstamp"])]
#[Index(name: "comment_visible", columns: ["visible"])]
class Comment implements EntityInterface
{
#[ORM\Id]
#[ORM\GeneratedValue]
#[ORM\Column(type: 'integer')]
private $id;
#[ORM\Column(type: 'integer')]
private $par;
#[ORM\Column(type: 'string', length: 255)]
private $type;
#[ORM\Column(type: 'integer')]
private $user;
#[ORM\Column(type: 'string', length: 255)]
private $author;
#[ORM\Column(type: 'integer')]
private $tstamp;
#[ORM\Column(type: 'string', length: 255)]
private $theme;
#[ORM\Column(type: 'text')]
private $cont;
#[ORM\Column(type: 'text')]
private $answer;
#[ORM\Column(type: 'boolean')]
private $visible;
#[ORM\Column(type: 'string', length: 3)]
private $lang;
public function getId(): ?int
{
return $this->id;
}
public function getPar(): ?int
{
return $this->par;
}
public function setPar(int $par): self
{
$this->par = $par;
return $this;
}
public function getType(): ?string
{
return $this->type;
}
public function setType(string $type): self
{
$this->type = $type;
return $this;
}
public function getUser(): ?int
{
return $this->user;
}
public function setUser(int $user): self
{
$this->user = $user;
return $this;
}
public function getAuthor(): ?string
{
return $this->author;
}
public function setAuthor(string $author): self
{
$this->author = $author;
return $this;
}
public function getTstamp(): ?int
{
return $this->tstamp;
}
public function setTstamp(int $tstamp): self
{
$this->tstamp = $tstamp;
return $this;
}
public function getTheme(): ?string
{
return $this->theme;
}
public function setTheme(string $theme): self
{
$this->theme = $theme;
return $this;
}
public function getCont(): ?string
{
return $this->cont;
}
public function setCont(string $cont): self
{
$this->cont = $cont;
return $this;
}
public function getAnswer(): ?string
{
return $this->answer;
}
public function setAnswer(string $answer): self
{
$this->answer = $answer;
return $this;
}
public function isVisible(): ?bool
{
return $this->visible;
}
public function setVisible(bool $visible): self
{
$this->visible = $visible;
return $this;
}
public function getLang(): ?string
{
return $this->lang;
}
public function setLang(string $lang): self
{
$this->lang = $lang;
return $this;
}
}