Webdav: ezcWebdavAutomaticPathFactory
[ ]
[ ]
[ ]
[ ]
[ ]
Class: ezcWebdavAutomaticPathFactory
|
Path factory that automatically detects local settings. [
source]
Implemented Interfaces
This class is necessary to calculate the correct path when a server uses rewrite rules for mapping directories to one or more webdav implementations. The basic class uses pathinfo to parse the requested file / collection.
Request: /path/to/webdav.php/path/to/file Result: /path/to/file
You may want to provide custome implementations for different mappings.
Member Variables
Method Summary
|
public void |
__construct(
)
Creates a new path factory. |
|
public string |
generateUriFromPath(
$path )
Generates a URI from a local path. |
|
public string |
parseUriToPath(
$uri )
Parses the given URI to a locally understandable path. |
Methods
__construct
void __construct(
)
Creates a new path factory.
Creates a new path factory to be used in ezcWebdavTransportOptions. This path factory automatically detects information from the running webserver and tries to automatically determine the suitable values.
A locally understandable path MUST NOT contain a trailing slash, but MUST always contain a starting slash. For the root URI the path "/" MUST be used.
generateUriFromPath
string generateUriFromPath(
string
$path )
Generates a URI from a local path.
This method receives a local $path string, representing a node in the local WebDAV store and translates it into a full qualified URI to be used as external reference.
Parameters
| Name |
Type |
Description |
$path |
string |
|
parseUriToPath
string parseUriToPath(
string
$uri )
Parses the given URI to a locally understandable path.
This method retrieves a URI (either full qualified or relative) and translates it into a local path, which can be understood by the WebDAV elements.
Parameters
| Name |
Type |
Description |
$uri |
string |
|
Last updated: Mon, 12 Nov 2007