src/Entity/Olympiad/Category.php line 16
<?php
namespace App\Entity\Olympiad;
use App\Entity\Traits\ActiveTrait;
use App\Entity\Traits\CreatedTrait;
use App\Entity\Traits\DeletedTrait;
use App\Entity\Traits\UserCreatedInterface;
use App\Entity\Traits\UserCreatedTrait;
use Doctrine\Common\Collections\Collection;
use Doctrine\ORM\Mapping as ORM;
#[ORM\Table(name: 'olympiad_category')]
#[ORM\Entity(repositoryClass: 'App\Repository\Olympiad\CategoryRepository')]
#[ORM\HasLifecycleCallbacks]
class Category implements UserCreatedInterface
{
use ActiveTrait;
use CreatedTrait;
use UserCreatedTrait;
use DeletedTrait;
/**
* @var int|null
*/
#[ORM\Id]
#[ORM\GeneratedValue(strategy: 'AUTO')]
#[ORM\Column(type: 'integer')]
private $id;
/**
* @var string|null
*/
#[ORM\Column(type: 'string')]
private $caption;
/**
* @var string|null
*/
#[ORM\Column(type: 'string', length: 150)]
private $slug;
/**
* @var string|null
*/
#[ORM\Column(type: 'string', length: 150, nullable: true)]
private $iconClass;
/**
* @var Collection|Discipline[]
*/
#[ORM\OneToMany(targetEntity: 'App\Entity\Olympiad\Discipline', mappedBy: 'category')]
private $disciplines;
/**
* @return int|null
*/
public function getId(): ?int
{
return $this->id;
}
/**
* @param int|null $id
*/
public function setId(?int $id): void
{
$this->id = $id;
}
/**
* @return string|null
*/
public function getCaption(): ?string
{
return $this->caption;
}
/**
* @param string|null $caption
*/
public function setCaption(?string $caption): void
{
$this->caption = $caption;
}
/**
* @return Discipline[]|Collection
*/
public function getDisciplines()
{
return $this->disciplines;
}
/**
* @param Discipline[]|Collection $disciplines
*/
public function setDisciplines($disciplines): void
{
$this->disciplines = $disciplines;
}
/**
* @return string|null
*/
public function getSlug(): ?string
{
return $this->slug;
}
/**
* @param string|null $slug
*/
public function setSlug(?string $slug): void
{
$this->slug = $slug;
}
/**
* @return string|null
*/
public function getIconClass(): ?string
{
return $this->iconClass;
}
/**
* @param string|null $iconClass
*/
public function setIconClass(?string $iconClass): void
{
$this->iconClass = $iconClass;
}
}