Token.php 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177
  1. <?php
  2. /**
  3. * This file is auto-generated.
  4. */
  5. declare(strict_types=1);
  6. namespace App\Entity\Token;
  7. use ApiPlatform\Metadata\ApiResource;
  8. use App;
  9. use App\Entity\Access\Access;
  10. use DateTimeInterface;
  11. use Doctrine\ORM\Mapping as ORM;
  12. #[ApiResource(operations: [])]
  13. #[ORM\Entity]
  14. class Token
  15. {
  16. #[ORM\Id]
  17. #[ORM\Column]
  18. #[ORM\GeneratedValue]
  19. private int $id;
  20. #[ORM\Column]
  21. private mixed $type;
  22. #[ORM\Column(type: 'date', options: ['nullable' => true])]
  23. private ?DateTimeInterface $expiryDate;
  24. #[ORM\Column]
  25. private mixed $token;
  26. #[ORM\Column(type: 'date', options: ['nullable' => true])]
  27. private ?DateTimeInterface $createDate;
  28. #[ORM\Column(type: 'date', options: ['nullable' => true])]
  29. private ?DateTimeInterface $updateDate;
  30. #[ORM\Column(type: 'integer', options: ['nullable' => true])]
  31. private int $legacyId;
  32. #[ORM\Column(type: 'integer', options: ['nullable' => true])]
  33. private int $createdBy;
  34. #[ORM\Column(type: 'integer', options: ['nullable' => true])]
  35. private int $updatedBy;
  36. #[ORM\Column(options: ['default' => false])]
  37. private bool $draft;
  38. #[ORM\ManyToOne(targetEntity: Access::class, cascade: [], inversedBy: 'tokens')]
  39. #[ORM\JoinColumn(referencedColumnName: 'id', nullable: false, onDelete: 'SET NULL')]
  40. private App\Entity\Access\Access $access;
  41. function getId(): int
  42. {
  43. return $this->id;
  44. }
  45. function setId(int $id): self
  46. {
  47. $this->id = $id;
  48. return $this;
  49. }
  50. function getType(): mixed
  51. {
  52. return $this->type;
  53. }
  54. function setType(mixed $type): self
  55. {
  56. $this->type = $type;
  57. return $this;
  58. }
  59. function getExpiryDate(): DateTimeInterface
  60. {
  61. return $this->expiryDate;
  62. }
  63. function setExpiryDate(DateTimeInterface $expiryDate): self
  64. {
  65. $this->expiryDate = $expiryDate;
  66. return $this;
  67. }
  68. function getToken(): mixed
  69. {
  70. return $this->token;
  71. }
  72. function setToken(mixed $token): self
  73. {
  74. $this->token = $token;
  75. return $this;
  76. }
  77. function getCreateDate(): DateTimeInterface
  78. {
  79. return $this->createDate;
  80. }
  81. function setCreateDate(DateTimeInterface $createDate): self
  82. {
  83. $this->createDate = $createDate;
  84. return $this;
  85. }
  86. function getUpdateDate(): DateTimeInterface
  87. {
  88. return $this->updateDate;
  89. }
  90. function setUpdateDate(DateTimeInterface $updateDate): self
  91. {
  92. $this->updateDate = $updateDate;
  93. return $this;
  94. }
  95. function getLegacyId(): int
  96. {
  97. return $this->legacyId;
  98. }
  99. function setLegacyId(int $legacyId): self
  100. {
  101. $this->legacyId = $legacyId;
  102. return $this;
  103. }
  104. function getCreatedBy(): int
  105. {
  106. return $this->createdBy;
  107. }
  108. function setCreatedBy(int $createdBy): self
  109. {
  110. $this->createdBy = $createdBy;
  111. return $this;
  112. }
  113. function getUpdatedBy(): int
  114. {
  115. return $this->updatedBy;
  116. }
  117. function setUpdatedBy(int $updatedBy): self
  118. {
  119. $this->updatedBy = $updatedBy;
  120. return $this;
  121. }
  122. function getDraft(): bool
  123. {
  124. return $this->draft;
  125. }
  126. function setDraft(bool $draft): self
  127. {
  128. $this->draft = $draft;
  129. return $this;
  130. }
  131. function getAccess(): App\Entity\Access\Access
  132. {
  133. return $this->access;
  134. }
  135. function setAccess(App\Entity\Access\Access $access): self
  136. {
  137. $this->access = $access;
  138. return $this;
  139. }
  140. }