2023-02-15 13:13:57 -05:00
|
|
|
<?php
|
2023-11-23 04:22:34 -05:00
|
|
|
|
2023-02-15 13:13:57 -05:00
|
|
|
declare(strict_types=1);
|
|
|
|
|
|
|
|
|
|
/**
|
2024-05-29 05:32:54 -04:00
|
|
|
* SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors
|
|
|
|
|
* SPDX-License-Identifier: AGPL-3.0-or-later
|
2023-02-15 13:13:57 -05:00
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
namespace OCA\UserStatus;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* @psalm-type UserStatusClearAtTimeType = "day"|"week"
|
|
|
|
|
*
|
|
|
|
|
* @psalm-type UserStatusClearAt = array{
|
|
|
|
|
* type: "period"|"end-of",
|
|
|
|
|
* time: int|UserStatusClearAtTimeType,
|
|
|
|
|
* }
|
|
|
|
|
*
|
|
|
|
|
* @psalm-type UserStatusPredefined = array{
|
|
|
|
|
* id: string,
|
|
|
|
|
* icon: string,
|
|
|
|
|
* message: string,
|
|
|
|
|
* clearAt: ?UserStatusClearAt,
|
|
|
|
|
* }
|
|
|
|
|
*
|
2023-12-29 12:11:35 -05:00
|
|
|
* @psalm-type UserStatusType = "online"|"away"|"dnd"|"busy"|"offline"|"invisible"
|
|
|
|
|
*
|
2023-02-15 13:13:57 -05:00
|
|
|
* @psalm-type UserStatusPublic = array{
|
|
|
|
|
* userId: string,
|
|
|
|
|
* message: ?string,
|
|
|
|
|
* icon: ?string,
|
|
|
|
|
* clearAt: ?int,
|
2023-12-29 12:11:35 -05:00
|
|
|
* status: UserStatusType,
|
2023-02-15 13:13:57 -05:00
|
|
|
* }
|
|
|
|
|
*
|
|
|
|
|
* @psalm-type UserStatusPrivate = UserStatusPublic&array{
|
|
|
|
|
* messageId: ?string,
|
|
|
|
|
* messageIsPredefined: bool,
|
|
|
|
|
* statusIsUserDefined: bool,
|
|
|
|
|
* }
|
|
|
|
|
*/
|
|
|
|
|
class ResponseDefinitions {
|
|
|
|
|
}
|