<?phpnamespace App\Entity\System;use Doctrine\ORM\Mapping as ORM;/** * @ORM\Entity(repositoryClass="App\Repository\System\CurrencyRepository") * * @ORM\Table(indexes={ * * @ORM\Index(name="currency_iso_code", columns={"iso_code"}) * }) */class Currency{ public const EURO_ISO_CODE = 'EUR'; public const POUND_ISO_CODE = 'GBP'; /** * @var int * * @ORM\Id * * @ORM\GeneratedValue() * * @ORM\Column(type="integer") */ private $id; /** * @var string * * @ORM\Column(type="string", length=3, unique=true) */ private $isoCode; /** * @ORM\Column(type="boolean", nullable=false) */ private bool $active; /** * @ORM\Column(type="float", nullable=true) */ private ?float $euroConversionRate; /** * @ORM\Column(type="string") */ private string $name; public function __construct() { $this->active = false; } /** * @return int */ public function getId(): int { return $this->id; } public function setId(int $id): self { $this->id = $id; return $this; } public function getIsoCode(): string { return $this->isoCode; } public function setIsoCode(string $isoCode): Currency { $this->isoCode = $isoCode; return $this; } public function isActive(): bool { return $this->active; } public function setActive(bool $active): Currency { $this->active = $active; return $this; } public function getEuroConversionRate(): ?float { return $this->euroConversionRate; } public function setEuroConversionRate(?float $euroConversionRate): Currency { $this->euroConversionRate = $euroConversionRate; return $this; } public function getName(): string { return $this->name; } public function setName(string $name): Currency { $this->name = $name; return $this; }}