src/Entity/Adresse.php line 9

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\AdresseRepository;
  4. use Doctrine\ORM\Mapping as ORM;
  5. #[ORM\Entity(repositoryClassAdresseRepository::class)]
  6. class Adresse
  7. {
  8.     #[ORM\Id]
  9.     #[ORM\GeneratedValue]
  10.     #[ORM\Column(type'integer')]
  11.     private $id;
  12.     #[ORM\Column(type'string'length255nullabletrue)]
  13.     private $pays;
  14.     #[ORM\Column(type'string'length255nullabletrue)]
  15.     private $adresse;
  16.     #[ORM\Column(type'string'length255nullabletrue)]
  17.     private $localite;
  18.     #[ORM\Column(type'integer'nullabletrue)]
  19.     private $code_postale;
  20.     #[ORM\Column(type'string'length255nullabletrue)]
  21.     private $titre;
  22.     #[ORM\ManyToOne(targetEntityUser::class, inversedBy'adresses')]
  23.     private $user;
  24.     #[ORM\ManyToOne(targetEntityGouvernorat::class, inversedBy'adresses')]
  25.     private $gouvernorat;
  26.     #[ORM\ManyToOne(targetEntityDelegation::class, inversedBy'adresses')]
  27.     private $delegation;
  28.     public function __construct()
  29.     {
  30.     }
  31.     public function getId(): ?int
  32.     {
  33.         return $this->id;
  34.     }
  35.     public function getPays(): ?string
  36.     {
  37.         return $this->pays;
  38.     }
  39.     public function setPays(string $pays): self
  40.     {
  41.         $this->pays $pays;
  42.         return $this;
  43.     }
  44.     public function getAdresse(): ?string
  45.     {
  46.         return $this->adresse;
  47.     }
  48.     public function setAdresse(string $adresse): self
  49.     {
  50.         $this->adresse $adresse;
  51.         return $this;
  52.     }
  53.     public function getLocalite(): ?string
  54.     {
  55.         return $this->localite;
  56.     }
  57.     public function setLocalite(string $localite): self
  58.     {
  59.         $this->localite $localite;
  60.         return $this;
  61.     }
  62.     public function getCodePostale(): ?int
  63.     {
  64.         return $this->code_postale;
  65.     }
  66.     public function setCodePostale(int $code_postale): self
  67.     {
  68.         $this->code_postale $code_postale;
  69.         return $this;
  70.     }
  71.     public function getTitre(): ?string
  72.     {
  73.         return $this->titre;
  74.     }
  75.     public function setTitre(string $titre): self
  76.     {
  77.         $this->titre $titre;
  78.         return $this;
  79.     }
  80.     // public function getEntreprise(): ?Entreprise
  81.     // {
  82.     //     return $this->entreprise;
  83.     // }
  84.     // public function setEntreprise(?Entreprise $entreprise): self
  85.     // {
  86.     //     $this->entreprise = $entreprise;
  87.     //     return $this;
  88.     // }
  89.     public function getUser(): ?User
  90.     {
  91.         return $this->user;
  92.     }
  93.     public function setUser(?User $user): self
  94.     {
  95.         $this->user $user;
  96.         return $this;
  97.     }
  98.     public function getGouvernorat(): ?Gouvernorat
  99.     {
  100.         return $this->gouvernorat;
  101.     }
  102.     public function setGouvernorat(?Gouvernorat $gouvernorat): self
  103.     {
  104.         $this->gouvernorat $gouvernorat;
  105.         return $this;
  106.     }
  107.     public function getDelegation(): ?Delegation
  108.     {
  109.         return $this->delegation;
  110.     }
  111.     public function setDelegation(?Delegation $delegation): self
  112.     {
  113.         $this->delegation $delegation;
  114.         return $this;
  115.     }
  116.     public function __toString()
  117.     {
  118.         return "Autres Adresses";
  119.     }
  120. }