src/Entity/Address.php line 11

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\AddressRepository;
  4. use Doctrine\ORM\Mapping as ORM;
  5. /**
  6.  * @ORM\Entity(repositoryClass=AddressRepository::class)
  7.  */
  8. class Address
  9. {
  10.     /**
  11.      * @ORM\Id
  12.      * @ORM\GeneratedValue
  13.      * @ORM\Column(type="integer")
  14.      */
  15.     private $id;
  16.     /**
  17.      * @ORM\Column(type="string", length=100, nullable=true)
  18.      */
  19.     private ?string $label null;
  20.     /**
  21.      * @ORM\Column(type="text", nullable=true)
  22.      */
  23.     private $address;
  24.     /**
  25.      * @ORM\Column(type="string", length=100, nullable=true)
  26.      */
  27.     private $country;
  28.     /**
  29.      * @ORM\Column(type="string", length=100, nullable=true)
  30.      */
  31.     private $region;
  32.     /**
  33.      * @ORM\Column(type="string", length=255, nullable=true)
  34.      */
  35.     private $city;
  36.     /**
  37.      * @ORM\Column(type="string", length=255, nullable=true)
  38.      */
  39.     private $zip;
  40.     /**
  41.      * @ORM\ManyToOne(targetEntity=User::class, inversedBy="multiAddress")
  42.      */
  43.     private ?User $user null;
  44.     /**
  45.      * @ORM\ManyToOne(targetEntity=Supplier::class, inversedBy="multiAddress")
  46.      */
  47.     private ?Supplier $supplier null;
  48.     public function getId(): ?int
  49.     {
  50.         return $this->id;
  51.     }
  52.     public function getLabel(): ?string
  53.     {
  54.         return $this->label;
  55.     }
  56.     public function setLabel(?string $label): self
  57.     {
  58.         $this->label $label;
  59.         return $this;
  60.     }
  61.     public function getAddress(): ?string
  62.     {
  63.         return $this->address;
  64.     }
  65.     public function setAddress(?string $address): self
  66.     {
  67.         $this->address $address;
  68.         return $this;
  69.     }
  70.     public function getCountry(): ?string
  71.     {
  72.         return $this->country;
  73.     }
  74.     public function setCountry(?string $country): self
  75.     {
  76.         $this->country $country;
  77.         return $this;
  78.     }
  79.     public function getRegion(): ?string
  80.     {
  81.         return $this->region;
  82.     }
  83.     public function setRegion(?string $region): self
  84.     {
  85.         $this->region $region;
  86.         return $this;
  87.     }
  88.     public function getCity(): ?string
  89.     {
  90.         return $this->city;
  91.     }
  92.     public function setCity(?string $city): self
  93.     {
  94.         $this->city $city;
  95.         return $this;
  96.     }
  97.     public function getZip(): ?string
  98.     {
  99.         return $this->zip;
  100.     }
  101.     public function setZip(?string $zip): self
  102.     {
  103.         $this->zip $zip;
  104.         return $this;
  105.     }
  106.     public function getUser(): ?User
  107.     {
  108.         return $this->user;
  109.     }
  110.     public function setUser(?User $user): self
  111.     {
  112.         $this->user $user;
  113.         return $this;
  114.     }
  115.     public function getSupplier(): ?Supplier
  116.     {
  117.         return $this->supplier;
  118.     }
  119.     public function setSupplier(?Supplier $supplier): self
  120.     {
  121.         $this->supplier $supplier;
  122.         return $this;
  123.     }
  124. }