Reminder.php 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. <?php
  2. declare(strict_types=1);
  3. /**
  4. * SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors
  5. * SPDX-License-Identifier: AGPL-3.0-or-later
  6. */
  7. namespace OCA\FilesReminders\Db;
  8. use DateTime;
  9. use OCP\AppFramework\Db\Entity;
  10. /**
  11. * @method void setUserId(string $userId)
  12. * @method string getUserId()
  13. *
  14. * @method void setFileId(int $fileId)
  15. * @method int getFileId()
  16. *
  17. * @method void setDueDate(DateTime $dueDate)
  18. * @method DateTime getDueDate()
  19. *
  20. * @method void setUpdatedAt(DateTime $updatedAt)
  21. * @method DateTime getUpdatedAt()
  22. *
  23. * @method void setCreatedAt(DateTime $createdAt)
  24. * @method DateTime getCreatedAt()
  25. *
  26. * @method void setNotified(bool $notified)
  27. * @method bool getNotified()
  28. */
  29. class Reminder extends Entity {
  30. protected $userId;
  31. protected $fileId;
  32. protected $dueDate;
  33. protected $updatedAt;
  34. protected $createdAt;
  35. protected $notified = false;
  36. public function __construct() {
  37. $this->addType('userId', 'string');
  38. $this->addType('fileId', 'integer');
  39. $this->addType('dueDate', 'datetime');
  40. $this->addType('updatedAt', 'datetime');
  41. $this->addType('createdAt', 'datetime');
  42. $this->addType('notified', 'boolean');
  43. }
  44. }