src/Entity/Commercial/LicensesOffer.php line 13

Open in your IDE?
  1. <?php
  2. namespace App\Entity\Commercial;
  3. use App\Entity\Common\LicenseEmbeddable;
  4. use App\Repository\Commercial\LicensesOfferRepository;
  5. use Doctrine\ORM\Mapping\Entity;
  6. use Doctrine\ORM\Mapping as ORM;
  7. use Symfony\Component\Validator\Constraints as Assert;
  8. #[Entity(repositoryClassLicensesOfferRepository::class)]
  9. #[ORM\Table(name'commercial_licenses_offers')]
  10. class LicensesOffer
  11. {
  12.     #[ORM\IdORM\GeneratedValueORM\Column(type'integer')]
  13.     private ?int $id null;
  14.     #[ORM\Embedded(class: LicenseEmbeddable::class)]
  15.     #[Assert\Valid]
  16.     private ?LicenseEmbeddable $license null;
  17.     public function getId(): ?int
  18.     {
  19.         return $this->id;
  20.     }
  21.     public function getLicense(): ?LicenseEmbeddable
  22.     {
  23.         return $this->license;
  24.     }
  25.     public function setLicense(?LicenseEmbeddable $license): static
  26.     {
  27.         $this->license $license;
  28.         return $this;
  29.     }
  30. }