1<?php 2 3namespace Sabre\CalDAV\Backend; 4 5use Sabre\CalDAV\Xml\Notification\NotificationInterface; 6 7/** 8 * Adds caldav notification support to a backend. 9 * 10 * Note: This feature is experimental, and may change in between different 11 * SabreDAV versions. 12 * 13 * Notifications are defined at: 14 * http://svn.calendarserver.org/repository/calendarserver/CalendarServer/trunk/doc/Extensions/caldav-notifications.txt 15 * 16 * These notifications are basically a list of server-generated notifications 17 * displayed to the user. Users can dismiss notifications by deleting them. 18 * 19 * The primary usecase is to allow for calendar-sharing. 20 * 21 * @copyright Copyright (C) 2007-2015 fruux GmbH (https://fruux.com/). 22 * @author Evert Pot (http://evertpot.com/) 23 * @license http://sabre.io/license/ Modified BSD License 24 */ 25interface NotificationSupport extends BackendInterface { 26 27 /** 28 * Returns a list of notifications for a given principal url. 29 * 30 * @param string $principalUri 31 * @return NotificationInterface[] 32 */ 33 function getNotificationsForPrincipal($principalUri); 34 35 /** 36 * This deletes a specific notifcation. 37 * 38 * This may be called by a client once it deems a notification handled. 39 * 40 * @param string $principalUri 41 * @param NotificationInterface $notification 42 * @return void 43 */ 44 function deleteNotification($principalUri, NotificationInterface $notification); 45 46} 47