src/Entity/System/Token.php line 16

Open in your IDE?
  1. <?php
  2. declare(strict_types=1);
  3. namespace App\Entity\System;
  4. use Doctrine\ORM\Mapping as ORM;
  5. /**
  6. * @ORM\Entity
  7. *
  8. * @ORM\Table(name="ps_token")
  9. *
  10. * @ORM\Entity(repositoryClass="App\Repository\System\TokenRepository")
  11. */
  12. class Token
  13. {
  14. /**
  15. * @ORM\Id
  16. *
  17. * @ORM\Column(type="integer", name="id_token")
  18. *
  19. * @ORM\GeneratedValue(strategy="AUTO")
  20. */
  21. private int $id;
  22. /**
  23. * @ORM\Column(type="integer", name="id_customer")
  24. */
  25. private int $customerId;
  26. /**
  27. * @ORM\Column(type="string", name="token")
  28. */
  29. private string $token;
  30. /**
  31. * @ORM\Column(type="boolean", name="used")
  32. */
  33. private bool $used;
  34. public function getId(): int
  35. {
  36. return $this->id;
  37. }
  38. public function getCustomerId(): int
  39. {
  40. return $this->customerId;
  41. }
  42. public function setCustomerId(int $customerId): Token
  43. {
  44. $this->customerId = $customerId;
  45. return $this;
  46. }
  47. public function getToken(): string
  48. {
  49. return $this->token;
  50. }
  51. public function setToken(string $token): Token
  52. {
  53. $this->token = $token;
  54. return $this;
  55. }
  56. public function isUsed(): bool
  57. {
  58. return $this->used;
  59. }
  60. public function setUsed(bool $used): Token
  61. {
  62. $this->used = $used;
  63. return $this;
  64. }
  65. }