| Total Complexity | 3 |
| Total Lines | 25 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 20 | trait IdTrait |
||
| 21 | { |
||
| 22 | /** |
||
| 23 | * @var string|null |
||
| 24 | * will be null when not inserted into the db yet |
||
| 25 | * |
||
| 26 | * @ORM\Id |
||
| 27 | * @ORM\Column(name="id", type="guid") |
||
| 28 | * @ORM\GeneratedValue(strategy="UUID") |
||
| 29 | */ |
||
| 30 | private $id; |
||
| 31 | |||
| 32 | public function getId(): ?string |
||
| 33 | { |
||
| 34 | return $this->id; |
||
| 35 | } |
||
| 36 | |||
| 37 | public function setId(string $id): void |
||
| 38 | { |
||
| 39 | $this->id = $id; |
||
| 40 | } |
||
| 41 | |||
| 42 | public function isPersistedInDatabase(): bool |
||
| 45 | } |
||
| 46 | } |
||
| 47 |