src/Entity/UrlRedirect.php line 29

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use Knp\DoctrineBehaviors\Contract\Entity\SoftDeletableInterface;
  4. use Knp\DoctrineBehaviors\Model\SoftDeletable\SoftDeletableTrait;
  5. use Knp\DoctrineBehaviors\Model\Blameable\BlameableTrait;
  6. use Knp\DoctrineBehaviors\Contract\Entity\BlameableInterface;
  7. use Knp\DoctrineBehaviors\Model\Timestampable\TimestampableTrait;
  8. use Knp\DoctrineBehaviors\Contract\Entity\TimestampableInterface;
  9. use Doctrine\Common\Collections\ArrayCollection;
  10. use Doctrine\Common\Collections\Collection;
  11. use Doctrine\ORM\Mapping as ORM;
  12. use Symfony\Component\Validator\Constraints as Assert;
  13. use Symfony\Component\HttpFoundation\File\UploadedFile;
  14. use Symfony\Component\HttpFoundation\File\File;
  15. use Symfony\Bridge\Doctrine\Validator\Constraints\UniqueEntity;
  16. /**
  17.  * @ORM\Entity
  18.  * @ORM\Table(name="url_redirect")
  19.  */
  20. class UrlRedirect implements BlameableInterfaceTimestampableInterfaceSoftDeletableInterface  {
  21.     use BlameableTrait;
  22.     use TimestampableTrait;
  23.     
  24.     use SoftDeletableTrait;
  25.     /**
  26.      * @var string
  27.      *
  28.      * @ORM\Column(name="from_url", type="text", nullable=true)
  29.      */
  30.     private $from;
  31.     /**
  32.      * @var string
  33.      *
  34.      * @ORM\Column(name="to_url", type="text", nullable=true)
  35.      */
  36.     private $to;
  37.     
  38.     /**
  39.      * @ORM\Id
  40.      * @ORM\Column(type="integer")
  41.      * @ORM\GeneratedValue(strategy="AUTO")
  42.      */
  43.     protected $id;
  44.     
  45.     /**
  46.      * @return string
  47.      */
  48.     public function getFrom(): ?string
  49.     {
  50.         return $this->from;
  51.     }
  52.     /**
  53.      * @param string $from
  54.      */
  55.     public function setFrom(string $from): void
  56.     {
  57.         $this->from $from;
  58.     }
  59.     /**
  60.      * @return string
  61.      */
  62.     public function getTo(): ?string
  63.     {
  64.         return $this->to;
  65.     }
  66.     /**
  67.      * @param string $to
  68.      */
  69.     public function setTo(string $to): void
  70.     {
  71.         $this->to $to;
  72.     }
  73. }