aboutsummaryrefslogtreecommitdiffstats
path: root/lib/public/User
diff options
context:
space:
mode:
authorJoas Schilling <213943+nickvergessen@users.noreply.github.com>2023-12-05 10:52:28 +0100
committerGitHub <noreply@github.com>2023-12-05 10:52:28 +0100
commitfffbb064170f461c6bdfa41fde8c45f43508eb57 (patch)
tree373d9d13f8c000cdc15eecc38947036cc9c9f016 /lib/public/User
parent61685e830a4ec5a6cb220841ae0b0ef233956b7d (diff)
parent9a206c6282a55c9fdeb99abe8684199c0f934d7f (diff)
downloadnextcloud-server-fffbb064170f461c6bdfa41fde8c45f43508eb57.tar.gz
nextcloud-server-fffbb064170f461c6bdfa41fde8c45f43508eb57.zip
Merge pull request #41962 from nextcloud/fix/dav/check-current-ooo-time
fix(dav): Make current ooo info time-dependent
Diffstat (limited to 'lib/public/User')
-rw-r--r--lib/public/User/IOutOfOfficeData.php19
1 files changed, 18 insertions, 1 deletions
diff --git a/lib/public/User/IOutOfOfficeData.php b/lib/public/User/IOutOfOfficeData.php
index 03444449d58..31281104382 100644
--- a/lib/public/User/IOutOfOfficeData.php
+++ b/lib/public/User/IOutOfOfficeData.php
@@ -25,14 +25,24 @@ declare(strict_types=1);
namespace OCP\User;
+use JsonSerializable;
use OCP\IUser;
/**
* DTO to hold out-of-office information of a user
*
+ * @psalm-type OutOfOfficeData = array{
+ * id: string,
+ * userId: string,
+ * startDate: int,
+ * endDate: int,
+ * shortMessage: string,
+ * message: string,
+ * }
+ *
* @since 28.0.0
*/
-interface IOutOfOfficeData {
+interface IOutOfOfficeData extends JsonSerializable {
/**
* Get the unique token assigned to the current out-of-office event
*
@@ -74,4 +84,11 @@ interface IOutOfOfficeData {
* @since 28.0.0
*/
public function getMessage(): string;
+
+ /**
+ * @return OutOfOfficeData
+ *
+ * @since 28.0.0
+ */
+ public function jsonSerialize(): array;
}