ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
MapGetToPropFind.php
Go to the documentation of this file.
1<?php
2
3namespace Sabre\DAV\Browser;
4
5use Sabre\DAV;
8
20
26 protected $server;
27
34 function initialize(DAV\Server $server) {
35
36 $this->server = $server;
37 $this->server->on('method:GET', [$this, 'httpGet'], 90);
38 }
39
48
49 $node = $this->server->tree->getNodeForPath($request->getPath());
50 if ($node instanceof DAV\IFile) return;
51
52 $subRequest = clone $request;
53 $subRequest->setMethod('PROPFIND');
54
55 $this->server->invokeMethod($subRequest, $response);
56 return false;
57
58 }
59
60}
foreach($paths as $path) $request
Definition: asyncclient.php:32
An exception for terminatinating execution or to throw for unit testing.
This is a simple plugin that will map any GET request for non-files to PROPFIND allprops-requests.
httpGet(RequestInterface $request, ResponseInterface $response)
This method intercepts GET requests to non-files, and changes it into an HTTP PROPFIND request.
initialize(DAV\Server $server)
Initializes the plugin and subscribes to events.
The baseclass for all server plugins.
Main DAV server class.
Definition: Server.php:23
This interface represents a file in the directory tree.
Definition: IFile.php:16
The RequestInterface represents a HTTP request.
This interface represents a HTTP response.
$response
$subRequest