src/Entity/FinancialParameter.php line 12

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Entity\Enum\FinancialParameterEnum;
  4. use App\Repository\FinancialParameterRepository;
  5. use Doctrine\ORM\Mapping as ORM;
  6. /**
  7.  * @ORM\Entity(repositoryClass=FinancialParameterRepository::class)
  8.  */
  9. class FinancialParameter
  10. {
  11.     /**
  12.      * @ORM\Id
  13.      * @ORM\GeneratedValue
  14.      * @ORM\Column(type="integer")
  15.      */
  16.     private int $id;
  17.     /**
  18.      * @ORM\Column(type="date")
  19.      */
  20.     private \DateTime $start;
  21.     /**
  22.      * @ORM\Column(type="date")
  23.      */
  24.     private \DateTime $end;
  25.     /**
  26.      * @ORM\Column(type="string", length=10)
  27.      */
  28.     private string $type;
  29.     /**
  30.      * @ORM\Column(type="float")
  31.      */
  32.     private float $value;
  33.     public function getId(): ?int
  34.     {
  35.         return $this->id;
  36.     }
  37.     public function getStart(): ?\DateTimeInterface
  38.     {
  39.         return $this->start;
  40.     }
  41.     public function setStart(\DateTimeInterface $start): self
  42.     {
  43.         $this->start $start;
  44.         return $this;
  45.     }
  46.     public function getEnd(): ?\DateTimeInterface
  47.     {
  48.         return $this->end;
  49.     }
  50.     public function setEnd(\DateTimeInterface $end): self
  51.     {
  52.         $this->end $end;
  53.         return $this;
  54.     }
  55.     public function getType(): ?string
  56.     {
  57.         return $this->type;
  58.     }
  59.     public function getTypeLabel(): ?string
  60.     {
  61.         return FinancialParameterEnum::getModelName($this->type);
  62.     }
  63.     public function setType(string $type): self
  64.     {
  65.         $this->type $type;
  66.         return $this;
  67.     }
  68.     public function getValue(): ?float
  69.     {
  70.         return $this->value;
  71.     }
  72.     public function setValue(float $value): self
  73.     {
  74.         $this->value $value;
  75.         return $this;
  76.     }
  77. }