diff options
Diffstat (limited to 'lib/public/Notification/IApp.php')
-rw-r--r-- | lib/public/Notification/IApp.php | 42 |
1 files changed, 13 insertions, 29 deletions
diff --git a/lib/public/Notification/IApp.php b/lib/public/Notification/IApp.php index 8f7b9b3d013..37c352d44cd 100644 --- a/lib/public/Notification/IApp.php +++ b/lib/public/Notification/IApp.php @@ -1,51 +1,35 @@ <?php + +declare(strict_types=1); /** - * @copyright Copyright (c) 2016, ownCloud, Inc. - * - * @author Joas Schilling <coding@schilljs.com> - * - * @license AGPL-3.0 - * - * This code is free software: you can redistribute it and/or modify - * it under the terms of the GNU Affero General Public License, version 3, - * as published by the Free Software Foundation. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Affero General Public License for more details. - * - * You should have received a copy of the GNU Affero General Public License, version 3, - * along with this program. If not, see <http://www.gnu.org/licenses/> - * + * SPDX-FileCopyrightText: 2016-2024 Nextcloud GmbH and Nextcloud contributors + * SPDX-FileCopyrightText: 2016 ownCloud, Inc. + * SPDX-License-Identifier: AGPL-3.0-only */ - namespace OCP\Notification; -/** - * Interface IApp - * - * @package OCP\Notification - * @since 9.0.0 - */ +use OCP\AppFramework\Attribute\Implementable; + +#[Implementable(since: '9.0.0')] interface IApp { /** * @param INotification $notification - * @throws \InvalidArgumentException When the notification is not valid + * @throws IncompleteNotificationException When the notification does not have all required fields set * @since 9.0.0 + * @since 30.0.0 throws {@see IncompleteNotificationException} instead of \InvalidArgumentException */ - public function notify(INotification $notification); + public function notify(INotification $notification): void; /** * @param INotification $notification * @since 9.0.0 */ - public function markProcessed(INotification $notification); + public function markProcessed(INotification $notification): void; /** * @param INotification $notification * @return int * @since 9.0.0 */ - public function getCount(INotification $notification); + public function getCount(INotification $notification): int; } |