ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
Sabre\DAV\ServerPlugin Class Reference

The baseclass for all server plugins. More...

+ Inheritance diagram for Sabre\DAV\ServerPlugin:
+ Collaboration diagram for Sabre\DAV\ServerPlugin:

Public Member Functions

 initialize (Server $server)
 This initializes the plugin. More...
 
 getFeatures ()
 This method should return a list of server-features. More...
 
 getHTTPMethods ($path)
 Use this method to tell the server this plugin defines additional HTTP methods. More...
 
 getPluginName ()
 Returns a plugin name. More...
 
 getSupportedReportSet ($uri)
 Returns a list of reports this plugin supports. More...
 
 getPluginInfo ()
 Returns a bunch of meta-data about the plugin. More...
 

Detailed Description

The baseclass for all server plugins.

Plugins can modify or extend the servers behaviour.

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

Definition at line 14 of file ServerPlugin.php.

Member Function Documentation

◆ getFeatures()

Sabre\DAV\ServerPlugin::getFeatures ( )

This method should return a list of server-features.

This is for example 'versioning' and is added to the DAV: header in an OPTIONS response.

Returns
array

Definition at line 37 of file ServerPlugin.php.

37  {
38 
39  return [];
40 
41  }

◆ getHTTPMethods()

Sabre\DAV\ServerPlugin::getHTTPMethods (   $path)

Use this method to tell the server this plugin defines additional HTTP methods.

This method is passed a uri. It should only return HTTP methods that are available for the specified uri.

Parameters
string$path
Returns
array

Definition at line 53 of file ServerPlugin.php.

53  {
54 
55  return [];
56 
57  }

◆ getPluginInfo()

Sabre\DAV\ServerPlugin::getPluginInfo ( )

Returns a bunch of meta-data about the plugin.

Providing this information is optional, and is mainly displayed by the Browser plugin.

The description key in the returned array may contain html and will not be sanitized.

Returns
array

Definition at line 100 of file ServerPlugin.php.

References Sabre\DAV\ServerPlugin\getPluginName().

100  {
101 
102  return [
103  'name' => $this->getPluginName(),
104  'description' => null,
105  'link' => null,
106  ];
107 
108  }
getPluginName()
Returns a plugin name.
+ Here is the call graph for this function:

◆ getPluginName()

Sabre\DAV\ServerPlugin::getPluginName ( )

Returns a plugin name.

Using this name other plugins will be able to access other plugins using ::getPlugin

Returns
string

Definition at line 67 of file ServerPlugin.php.

Referenced by Sabre\DAV\Server\addPlugin(), and Sabre\DAV\ServerPlugin\getPluginInfo().

67  {
68 
69  return get_class($this);
70 
71  }
+ Here is the caller graph for this function:

◆ getSupportedReportSet()

Sabre\DAV\ServerPlugin::getSupportedReportSet (   $uri)

Returns a list of reports this plugin supports.

This will be used in the {DAV:}supported-report-set property. Note that you still need to subscribe to the 'report' event to actually implement them

Parameters
string$uri
Returns
array

Definition at line 83 of file ServerPlugin.php.

83  {
84 
85  return [];
86 
87  }

◆ initialize()

Sabre\DAV\ServerPlugin::initialize ( Server  $server)
abstract

This initializes the plugin.

This function is called by Sabre, after addPlugin is called.

This method should set up the required event subscriptions.

Parameters
Server$server
Returns
void

Referenced by Sabre\DAV\Server\addPlugin().

+ Here is the caller graph for this function:

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