ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
Sabre\CalDAV\Notifications\Node Class Reference

This node represents a single notification. More...

+ Inheritance diagram for Sabre\CalDAV\Notifications\Node:
+ Collaboration diagram for Sabre\CalDAV\Notifications\Node:

Public Member Functions

 __construct (CalDAV\Backend\NotificationSupport $caldavBackend, $principalUri, NotificationInterface $notification)
 Constructor. More...
 
 getName ()
 Returns the path name for this notification. More...
 
 getETag ()
 Returns the etag for the notification. More...
 
 getNotificationType ()
 This method must return an xml element, using the Sabre classes. More...
 
 delete ()
 Deletes this notification. More...
 
 getOwner ()
 Returns the owner principal. More...
 
- Public Member Functions inherited from Sabre\DAV\File
 put ($data)
 Replaces the contents of the file. More...
 
 get ()
 Returns the data. More...
 
 getSize ()
 Returns the size of the file, in bytes. More...
 
 getETag ()
 Returns the ETag for a file. More...
 
 getContentType ()
 Returns the mime-type for a file. More...
 
- Public Member Functions inherited from Sabre\DAV\Node
 getLastModified ()
 Returns the last modification time as a unix timestamp. More...
 
 delete ()
 Deletes the current node. More...
 
 setName ($name)
 Renames the node. More...
 
- Public Member Functions inherited from Sabre\DAVACL\IACL
 getGroup ()
 Returns a group principal. More...
 
 getACL ()
 Returns a list of ACE's for this node. More...
 
 setACL (array $acl)
 Updates the ACL. More...
 
 getSupportedPrivilegeSet ()
 Returns the list of supported privileges for this node. More...
 

Protected Attributes

 $caldavBackend
 
 $notification
 
 $principalUri
 

Detailed Description

This node represents a single notification.

The signature is mostly identical to that of Sabre, but the get() method MUST return an xml document that matches the requirements of the 'caldav-notifications.txt' spec.

Author
Evert Pot (http://evertpot.com/) http://sabre.io/license/ Modified BSD License

Definition at line 21 of file Node.php.

Constructor & Destructor Documentation

◆ __construct()

Sabre\CalDAV\Notifications\Node::__construct ( CalDAV\Backend\NotificationSupport  $caldavBackend,
  $principalUri,
NotificationInterface  $notification 
)

Constructor.

Parameters
CalDAV\Backend\NotificationSupport$caldavBackend
string$principalUri
NotificationInterface$notification

Definition at line 53 of file Node.php.

References Sabre\CalDAV\Notifications\Node\$caldavBackend, Sabre\CalDAV\Notifications\Node\$notification, Sabre\CalDAV\Notifications\Node\$principalUri, and notification().

53  {
54 
55  $this->caldavBackend = $caldavBackend;
56  $this->principalUri = $principalUri;
57  $this->notification = $notification;
58 
59  }
notification()
Definition: notification.php:2
+ Here is the call graph for this function:

Member Function Documentation

◆ delete()

Sabre\CalDAV\Notifications\Node::delete ( )

Deletes this notification.

Returns
void

Implements Sabre\DAV\INode.

Definition at line 102 of file Node.php.

References Sabre\CalDAV\Notifications\Node\getOwner(), and notification().

102  {
103 
104  $this->caldavBackend->deleteNotification($this->getOwner(), $this->notification);
105 
106  }
getOwner()
Returns the owner principal.
Definition: Node.php:115
notification()
Definition: notification.php:2
+ Here is the call graph for this function:

◆ getETag()

Sabre\CalDAV\Notifications\Node::getETag ( )

Returns the etag for the notification.

The etag must be surrounded by litteral double-quotes.

Returns
string

Implements Sabre\CalDAV\Notifications\INode.

Definition at line 79 of file Node.php.

References notification().

79  {
80 
81  return $this->notification->getETag();
82 
83  }
notification()
Definition: notification.php:2
+ Here is the call graph for this function:

◆ getName()

Sabre\CalDAV\Notifications\Node::getName ( )

Returns the path name for this notification.

Returns
string

Implements Sabre\DAV\INode.

Definition at line 66 of file Node.php.

References notification().

66  {
67 
68  return $this->notification->getId() . '.xml';
69 
70  }
notification()
Definition: notification.php:2
+ Here is the call graph for this function:

◆ getNotificationType()

Sabre\CalDAV\Notifications\Node::getNotificationType ( )

This method must return an xml element, using the Sabre classes.

Returns
NotificationInterface

Implements Sabre\CalDAV\Notifications\INode.

Definition at line 91 of file Node.php.

References Sabre\CalDAV\Notifications\Node\$notification.

91  {
92 
93  return $this->notification;
94 
95  }

◆ getOwner()

Sabre\CalDAV\Notifications\Node::getOwner ( )

Returns the owner principal.

This must be a url to a principal, or null if there's no owner

Returns
string|null

Implements Sabre\DAVACL\IACL.

Definition at line 115 of file Node.php.

References Sabre\CalDAV\Notifications\Node\$principalUri.

Referenced by Sabre\CalDAV\Notifications\Node\delete().

115  {
116 
117  return $this->principalUri;
118 
119  }
+ Here is the caller graph for this function:

Field Documentation

◆ $caldavBackend

Sabre\CalDAV\Notifications\Node::$caldavBackend
protected

Definition at line 30 of file Node.php.

Referenced by Sabre\CalDAV\Notifications\Node\__construct().

◆ $notification

Sabre\CalDAV\Notifications\Node::$notification
protected

◆ $principalUri

Sabre\CalDAV\Notifications\Node::$principalUri
protected

The documentation for this class was generated from the following file: