aboutsummaryrefslogtreecommitdiffstats
path: root/lib/public/Notification/INotifier.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/public/Notification/INotifier.php')
-rw-r--r--lib/public/Notification/INotifier.php21
1 files changed, 20 insertions, 1 deletions
diff --git a/lib/public/Notification/INotifier.php b/lib/public/Notification/INotifier.php
index 5e2a47266ad..b730b1d8015 100644
--- a/lib/public/Notification/INotifier.php
+++ b/lib/public/Notification/INotifier.php
@@ -1,4 +1,5 @@
<?php
+declare(strict_types=1);
/**
* @copyright Copyright (c) 2016, ownCloud, Inc.
*
@@ -29,12 +30,30 @@ namespace OCP\Notification;
* @since 9.0.0
*/
interface INotifier {
+
+ /**
+ * Identifier of the notifier, only use [a-z0-9_]
+ *
+ * @return string
+ * @since 17.0.0
+ */
+ public function getID(): string;
+
+ /**
+ * Human readable name describing the notifier
+ *
+ * @return string
+ * @since 17.0.0
+ */
+ public function getName(): string;
+
/**
* @param INotification $notification
* @param string $languageCode The code of the language that should be used to prepare the notification
* @return INotification
* @throws \InvalidArgumentException When the notification was not prepared by a notifier
+ * @throws AlreadyProcessedException When the notification is not needed anymore and should be deleted
* @since 9.0.0
*/
- public function prepare(INotification $notification, $languageCode);
+ public function prepare(INotification $notification, string $languageCode): INotification;
}