src/Entity/Links.php line 13

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\LinksRepository;
  4. use Doctrine\Common\Collections\ArrayCollection;
  5. use Doctrine\Common\Collections\Collection;
  6. use Doctrine\ORM\Mapping as ORM;
  7. /**
  8.  * @ORM\Entity(repositoryClass=LinksRepository::class)
  9.  */
  10. class Links
  11. {
  12.     use \App\Traits\CommonTrt;
  13.     /**
  14.      * @ORM\Id
  15.      * @ORM\GeneratedValue
  16.      * @ORM\Column(type="integer")
  17.      */
  18.     private $id;
  19.     /**
  20.      * @ORM\Column(type="string", length=255)
  21.      */
  22.     private $title;
  23.     /**
  24.      * @ORM\Column(type="string", length=255, nullable=true)
  25.      */
  26.     private $url;
  27.     /**
  28.      * @ORM\Column(type="string", length=255)
  29.      */
  30.     private $slug;
  31.     public function getId(): ?int
  32.     {
  33.         return $this->id;
  34.     }
  35.     public function getTitle(): ?string
  36.     {
  37.         return $this->title;
  38.     }
  39.     public function setTitle(string $title): self
  40.     {
  41.         $this->title = $title;
  42.         return $this;
  43.     }
  44.     public function getUrl(): ?string
  45.     {
  46.         return $this->url;
  47.     }
  48.     public function setUrl(?string $url): self
  49.     {
  50.         $this->url = $url;
  51.         return $this;
  52.     }
  53.     public function __toString()
  54.     {
  55.         return $this->title;
  56.     }
  57.     public function getSlug(): ?string
  58.     {
  59.         return $this->slug;
  60.     }
  61.     public function setSlug(string $slug): self
  62.     {
  63.         $this->slug = $slug;
  64.         return $this;
  65.     }
  66. }