diff options
author | Daniel Weipert <git@mail.dweipert.de> | 2025-08-19 15:50:42 +0200 |
---|---|---|
committer | Daniel Weipert <git@mail.dweipert.de> | 2025-08-19 16:11:52 +0200 |
commit | d08f4c83470c25d35d24594bd73e4effdac191a0 (patch) | |
tree | 8320e4d0750776891fa5680ce5904de714128fce /src/Support | |
parent | a0ad1f5e7fac279b33ea09ca0e347cd7d02cd8ec (diff) |
database migrations and models for users, devices, tokens
Diffstat (limited to 'src/Support')
-rw-r--r-- | src/Support/ConnectsToDatabase.php | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/src/Support/ConnectsToDatabase.php b/src/Support/ConnectsToDatabase.php new file mode 100644 index 0000000..29f566c --- /dev/null +++ b/src/Support/ConnectsToDatabase.php @@ -0,0 +1,24 @@ +<?php + +namespace App\Support; + +interface ConnectsToDatabase +{ + /** + * @param array<string,mixed> $row + */ + public static function fromDatabase(array $row): self; + + public static function fetch(): ?self; + + /** + * @return array<self> + */ + public static function fetchAll(): array; + + public function insert(): bool; + + public function update(): bool; + + public function delete(): bool; +} |