src/Entity/DeathCertificate.php line 11

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\DeathCertificateRepository;
  4. use Doctrine\ORM\Mapping as ORM;
  5. use Gedmo\Mapping\Annotation as Gedmo;
  6. use Symfony\Component\Validator\Constraints as Assert;
  7. #[ORM\Entity(repositoryClassDeathCertificateRepository::class), ORM\Table(name'death_certificates')]
  8. class DeathCertificate
  9. {
  10.     #[ORM\IdORM\GeneratedValueORM\Column(type'integer')]
  11.     private $id;
  12.     #[ORM\OneToOne(inversedBy'deathCertificate'targetEntityCases::class, cascade: ['persist''remove']), ORM\JoinColumn(nullablefalse)]
  13.     private $case;
  14.     #[ORM\Column(type'string'length255nullabletrue)]
  15.     private $immediateCause;
  16.     #[ORM\Column(type'string'length255nullabletrue)]
  17.     private $antecedentCauseB;
  18.     #[ORM\Column(type'string'length255nullabletrue)]
  19.     private $antecedentCauseC;
  20.     #[ORM\Column(type'string'length255nullabletrue)]
  21.     private $otherSignificantConditions;
  22.     #[ORM\Column(type'string'length255nullabletrue)]
  23.     private $onSetInterval;
  24.     #[ORM\Column(type'string'length255nullabletrue)]
  25.     private $howInjuryOccurred;
  26.     #[ORM\Column(type'string'length255), Assert\NotBlank]
  27.     private $mannerOfDeath;
  28.     #[ORM\Column(type'boolean')]
  29.     private $isPregnancyDeath false;
  30.     #[ORM\Column(type'boolean')]
  31.     private $isDelivery false;
  32.     #[ORM\Column(type'datetime'), Assert\NotBlank]
  33.     private $diedAt;
  34.     #[Gedmo\Blameable(on'create'), ORM\ManyToOne(targetEntityUser::class), ORM\JoinColumn(nullablefalse)]
  35.     private $createdBy;
  36.     #[Gedmo\Blameable(on'update'), ORM\ManyToOne(targetEntityUser::class)]
  37.     private $updatedBy;
  38.     #[Gedmo\Timestampable(on'create'), ORM\Column(type'datetime')]
  39.     private $createdAt;
  40.     #[Gedmo\Timestampable(on'update'), ORM\Column(type'datetime')]
  41.     private $updatedAt;
  42.     public function getId(): ?int
  43.     {
  44.         return $this->id;
  45.     }
  46.     public function getCase(): ?Cases
  47.     {
  48.         return $this->case;
  49.     }
  50.     public function setCase(Cases $case): self
  51.     {
  52.         $this->case $case;
  53.         return $this;
  54.     }
  55.     public function getImmediateCause(): ?string
  56.     {
  57.         return $this->immediateCause;
  58.     }
  59.     public function setImmediateCause(?string $immediateCause): self
  60.     {
  61.         $this->immediateCause $immediateCause;
  62.         return $this;
  63.     }
  64.     public function getAntecedentCauseB(): ?string
  65.     {
  66.         return $this->antecedentCauseB;
  67.     }
  68.     public function setAntecedentCauseB(?string $antecedentCauseB): self
  69.     {
  70.         $this->antecedentCauseB $antecedentCauseB;
  71.         return $this;
  72.     }
  73.     public function getAntecedentCauseC(): ?string
  74.     {
  75.         return $this->antecedentCauseC;
  76.     }
  77.     public function setAntecedentCauseC(?string $antecedentCauseC): self
  78.     {
  79.         $this->antecedentCauseC $antecedentCauseC;
  80.         return $this;
  81.     }
  82.     public function getOtherSignificantConditions(): ?string
  83.     {
  84.         return $this->otherSignificantConditions;
  85.     }
  86.     public function setOtherSignificantConditions(?string $otherSignificantConditions): self
  87.     {
  88.         $this->otherSignificantConditions $otherSignificantConditions;
  89.         return $this;
  90.     }
  91.     public function getOnSetInterval(): ?string
  92.     {
  93.         return $this->onSetInterval;
  94.     }
  95.     public function setOnSetInterval(?string $onSetInterval): self
  96.     {
  97.         $this->onSetInterval $onSetInterval;
  98.         return $this;
  99.     }
  100.     public function getHowInjuryOccurred(): ?string
  101.     {
  102.         return $this->howInjuryOccurred;
  103.     }
  104.     public function setHowInjuryOccurred(?string $howInjuryOccurred): self
  105.     {
  106.         $this->howInjuryOccurred $howInjuryOccurred;
  107.         return $this;
  108.     }
  109.     public function getMannerOfDeath(): ?string
  110.     {
  111.         return $this->mannerOfDeath;
  112.     }
  113.     public function setMannerOfDeath(string $mannerOfDeath): self
  114.     {
  115.         $this->mannerOfDeath $mannerOfDeath;
  116.         return $this;
  117.     }
  118.     public function getIsPregnancyDeath(): ?bool
  119.     {
  120.         return $this->isPregnancyDeath;
  121.     }
  122.     public function setIsPregnancyDeath(bool $isPregnancyDeath): self
  123.     {
  124.         $this->isPregnancyDeath $isPregnancyDeath;
  125.         return $this;
  126.     }
  127.     public function getIsDelivery(): ?bool
  128.     {
  129.         return $this->isDelivery;
  130.     }
  131.     public function setIsDelivery(bool $isDelivery): self
  132.     {
  133.         $this->isDelivery $isDelivery;
  134.         return $this;
  135.     }
  136.     public function getDiedAt(): ?\DateTimeInterface
  137.     {
  138.         return $this->diedAt;
  139.     }
  140.     public function setDiedAt(\DateTimeInterface $diedAt): self
  141.     {
  142.         $this->diedAt $diedAt;
  143.         return $this;
  144.     }
  145.     public function getCreatedBy(): ?User
  146.     {
  147.         return $this->createdBy;
  148.     }
  149.     public function getUpdatedBy(): ?User
  150.     {
  151.         return $this->updatedBy;
  152.     }
  153.     public function getCreatedAt(): ?\DateTimeInterface
  154.     {
  155.         return $this->createdAt;
  156.     }
  157.     public function getUpdatedAt(): ?\DateTimeInterface
  158.     {
  159.         return $this->updatedAt;
  160.     }
  161. }