src/Entity/ContactMedecin.php line 19

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use Doctrine\ORM\Mapping as ORM;
  4. use Symfony\Component\Validator\Constraints as Assert;
  5. use App\Entity\SpecialiteDocteur as SpecialiteDocteur;
  6. use ApiPlatform\Core\Annotation\ApiResource;
  7. use Doctrine\Common\Collections\ArrayCollection;
  8. /**
  9.  * TODO: depecreated to delete
  10.  * ContactMedecin
  11.  *
  12.  * @ApiResource
  13.  * @ORM\Table()
  14.  * @ORM\Entity(repositoryClass="App\Entity\ContactMedecinRepository")
  15.  */
  16. class ContactMedecin
  17. {
  18.     /**
  19.      * @var int
  20.      *
  21.      * @ORM\Column(name="id", type="integer")
  22.      * @ORM\Id
  23.      * @ORM\GeneratedValue(strategy="AUTO")
  24.      */
  25.     private $id;
  26.     /**
  27.      * @var string
  28.      *
  29.      * @ORM\Column(name="genre", type="string", length=100)
  30.      *
  31.      */
  32.     private $genre;
  33.     /**
  34.      * @var string
  35.      *
  36.      * @ORM\Column(name="nom", type="string", length=100)
  37.      *
  38.      * @Assert\NotBlank()
  39.      */
  40.     private $nom;
  41.     /**
  42.      * @var string
  43.      *
  44.      * @ORM\Column(name="prenom", type="string", length=100)
  45.      *
  46.      * @Assert\NotBlank()
  47.      */
  48.     private $prenom;
  49.     /**
  50.      * @var string
  51.      *
  52.      * @ORM\Column(name="email", type="string", length=255)
  53.      *
  54.      * @Assert\NotBlank()
  55.      */
  56.     private $email;
  57.     /**
  58.      * @var string
  59.      *
  60.      * @ORM\Column(name="tel", type="string", length=20)
  61.      *
  62.      * @Assert\NotBlank()
  63.      */
  64.     private $tel;
  65.     /**
  66.      * @var ArrayCollection
  67.      *
  68.      * @ORM\ManyToOne(targetEntity="App\Entity\SpecialiteDocteur")
  69.      */
  70.     private $specialite;
  71.     public function __toString()
  72.     {
  73.         return ($this->getNom()) ? $this->getNom() : '';
  74.     }
  75.     /**
  76.      * Get id
  77.      *
  78.      * @return integer
  79.      */
  80.     public function getId()
  81.     {
  82.         return $this->id;
  83.     }
  84.     /**
  85.      * Get genre
  86.      *
  87.      * @return string
  88.      */
  89.     public function getGenre()
  90.     {
  91.         return $this->genre;
  92.     }
  93.     /**
  94.      * Set genre
  95.      *
  96.      * @param string $genre
  97.      *
  98.      * @return ContactMedecin
  99.      */
  100.     public function setGenre($genre)
  101.     {
  102.         $this->genre $genre;
  103.         return $this;
  104.     }
  105.     /**
  106.      * Get nom
  107.      *
  108.      * @return string
  109.      */
  110.     public function getNom()
  111.     {
  112.         return $this->nom;
  113.     }
  114.     /**
  115.      * Set nom
  116.      *
  117.      * @param string $nom
  118.      *
  119.      * @return ContactMedecin
  120.      */
  121.     public function setNom($nom)
  122.     {
  123.         $this->nom $nom;
  124.         return $this;
  125.     }
  126.     /**
  127.      * Get prenom
  128.      *
  129.      * @return string
  130.      */
  131.     public function getPrenom()
  132.     {
  133.         return $this->prenom;
  134.     }
  135.     /**
  136.      * Set prenom
  137.      *
  138.      * @param string $prenom
  139.      *
  140.      * @return ContactMedecin
  141.      */
  142.     public function setPrenom($prenom)
  143.     {
  144.         $this->prenom $prenom;
  145.         return $this;
  146.     }
  147.     /**
  148.      * Get email
  149.      *
  150.      * @return string
  151.      */
  152.     public function getEmail()
  153.     {
  154.         return $this->email;
  155.     }
  156.     /**
  157.      * Set email
  158.      *
  159.      * @param string $email
  160.      *
  161.      * @return ContactMedecin
  162.      */
  163.     public function setEmail($email)
  164.     {
  165.         $this->email $email;
  166.         return $this;
  167.     }
  168.     /**
  169.      * Get tel
  170.      *
  171.      * @return string
  172.      */
  173.     public function getTel()
  174.     {
  175.         return $this->tel;
  176.     }
  177.     /**
  178.      * Set tel
  179.      *
  180.      * @param string $tel
  181.      *
  182.      * @return ContactMedecin
  183.      */
  184.     public function setTel($tel)
  185.     {
  186.         $this->tel $tel;
  187.         return $this;
  188.     }
  189.     /**
  190.      * Get specialite
  191.      *
  192.      * @return ArrayCollection
  193.      */
  194.     public function getSpecialite()
  195.     {
  196.         return $this->specialite;
  197.     }
  198.     /**
  199.      * Set specialite
  200.      *
  201.      * @param SpecialiteDocteur $specialite
  202.      *
  203.      * @return ContactMedecin
  204.      */
  205.     public function setSpecialite(SpecialiteDocteur $specialite)
  206.     {
  207.         $this->specialite $specialite;
  208.         return $this;
  209.     }
  210. }