<?php
namespace App\Entity;
use App\Repository\Icd10DiseaseRepository;
use Doctrine\ORM\Mapping as ORM;
#[ORM\Entity(repositoryClass: Icd10DiseaseRepository::class), ORM\Table(name: 'icd10_diseases')]
class Icd10Disease implements \Stringable
{
#[ORM\Id, ORM\GeneratedValue, ORM\Column(type: 'integer')]
private $id;
#[ORM\Column(type: 'string', length: 4)]
private $code;
#[ORM\Column(type: 'string', length: 255)]
private $name;
#[ORM\ManyToOne(targetEntity: Icd10CauseGroup::class, inversedBy: 'icd10Diseases')]
#[ORM\JoinColumn(name: 'cause_group_id', nullable: false)]
private $causeGroup;
#[ORM\ManyToOne(targetEntity: Icd10CauseSubGroup::class, inversedBy: 'icd10Diseases')]
#[ORM\JoinColumn(name: 'cause_sub_group_id', nullable: false)]
private $causeSubGroup;
#[ORM\Column(type: 'text', nullable: true)]
private $supportiveAdvice;
#[ORM\Column(type: 'text', nullable: true)]
private $pharmaTreatment;
public function getId(): ?int
{
return $this->id;
}
public function getCode(): ?string
{
return $this->code;
}
public function setCode(string $code): self
{
$this->code = $code;
return $this;
}
public function getName(): ?string
{
return $this->name;
}
public function setName(string $name): self
{
$this->name = $name;
return $this;
}
public function getCauseGroup(): ?Icd10CauseGroup
{
return $this->causeGroup;
}
public function setCauseGroup(?Icd10CauseGroup $causeGroup): self
{
$this->causeGroup = $causeGroup;
return $this;
}
public function getCauseSubGroup(): ?Icd10CauseSubGroup
{
return $this->causeSubGroup;
}
public function setCauseSubGroup(?Icd10CauseSubGroup $causeSubGroup): self
{
$this->causeSubGroup = $causeSubGroup;
return $this;
}
public function getSupportiveAdvice(): ?string
{
return $this->supportiveAdvice;
}
public function setSupportiveAdvice(string $supportiveAdvice): self
{
$this->supportiveAdvice = $supportiveAdvice;
return $this;
}
public function getPharmaTreatment(): ?string
{
return $this->pharmaTreatment;
}
public function setPharmaTreatment(string $pharmaTreatment): self
{
$this->pharmaTreatment = $pharmaTreatment;
return $this;
}
public function __toString(): string
{
return (string) $this->getName();
}
}