summaryrefslogtreecommitdiff
path: root/includes/stream_wrappers.inc
diff options
context:
space:
mode:
authorDries <dries@buytaert.net>2011-10-16 12:52:29 -0400
committerDries <dries@buytaert.net>2011-10-16 12:52:29 -0400
commit1c5d72c84f754845da04d36359451915f7c10bd2 (patch)
tree90a27a4fdad6138941ee5e92748bd6b7edd488f7 /includes/stream_wrappers.inc
parenta11b4c61473976f99a49af318e65569a443155f4 (diff)
downloadbrdo-1c5d72c84f754845da04d36359451915f7c10bd2.tar.gz
brdo-1c5d72c84f754845da04d36359451915f7c10bd2.tar.bz2
- Patch #1307332 by pillarsdotnet: improve the docs for DrupalLocalStreamWrapper::getLocalPath() function.
Diffstat (limited to 'includes/stream_wrappers.inc')
-rw-r--r--includes/stream_wrappers.inc16
1 files changed, 12 insertions, 4 deletions
diff --git a/includes/stream_wrappers.inc b/includes/stream_wrappers.inc
index 9a9b06171..e47668e3a 100644
--- a/includes/stream_wrappers.inc
+++ b/includes/stream_wrappers.inc
@@ -356,10 +356,18 @@ abstract class DrupalLocalStreamWrapper implements DrupalStreamWrapperInterface
}
/**
- * Return the local filesystem path.
- *
- * @param $uri
- * Optional URI, supplied when doing a move or rename.
+ * Returns the canonical absolute path of the URI, if possible.
+ *
+ * @param string $uri
+ * (optional) The stream wrapper URI to be converted to a canonical
+ * absolute path. This may point to a directory or another type of file.
+ *
+ * @return string|false
+ * If $uri is not set, returns the canonical absolute path of the URI
+ * previously set by the DrupalStreamWrapperInterface::setUri() function.
+ * If $uri is set and valid for this class, returns its canonical absolute
+ * path, as determined by the realpath() function. If $uri is set but not
+ * valid, returns FALSE.
*/
protected function getLocalPath($uri = NULL) {
if (!isset($uri)) {