Lines Matching refs:uri

323      * @param string $uri
326 function setBaseUri($uri) { argument
329 if ($uri[strlen($uri) - 1] !== '/')
330 $uri .= '/';
332 $this->baseUri = $uri;
359 $uri = $this->httpRequest->getRawServerValue('REQUEST_URI');
365 if ($pos = strpos($uri, '?'))
366 $uri = substr($uri, 0, $pos);
373 $decodedUri = URLUtil::decodePath($uri);
381 …throw new Exception('The REQUEST_URI (' . $uri . ') did not end with the contents of PATH_INFO (' …
528 * @param string $uri
532 function calculateUri($uri) { argument
534 if ($uri[0] != '/' && strpos($uri, '://')) {
536 $uri = parse_url($uri, PHP_URL_PATH);
540 $uri = Uri\normalize(str_replace('//', '/', $uri));
543 if (strpos($uri, $baseUri) === 0) {
545 return trim(URLUtil::decodePath(substr($uri, strlen($baseUri))), '/');
549 } elseif ($uri . '/' === $baseUri) {
555 …throw new Exception\Forbidden('Requested uri (' . $uri . ') is out of base uri (' . $this->getBase…
1007 * @param string $uri
1012 function createFile($uri, $data, &$etag = null) { argument
1014 list($dir, $name) = URLUtil::splitPath($uri);
1016 if (!$this->emit('beforeBind', [$uri])) return false;
1029 if (!$this->emit('beforeCreateFile', [$uri, &$data, $parent, &$modified])) return false;
1037 $this->emit('afterBind', [$uri]);
1038 $this->emit('afterCreateFile', [$uri, $parent]);
1048 * @param string $uri
1053 function updateFile($uri, $data, &$etag = null) { argument
1055 $node = $this->tree->getNodeForPath($uri);
1063 if (!$this->emit('beforeWriteContent', [$uri, $node, &$data, &$modified])) return false;
1067 $this->emit('afterWriteContent', [$uri, $node]);
1077 * @param string $uri
1080 function createDirectory($uri) { argument
1082 $this->createCollection($uri, new MkCol(['{DAV:}collection'], []));
1089 * @param string $uri The new uri
1093 function createCollection($uri, MkCol $mkCol) { argument
1095 list($parentUri, $newName) = URLUtil::splitPath($uri);
1123 if (!$this->emit('beforeBind', [$uri])) return;
1153 $this->emit('propPatch', [$uri, $mkCol]);
1160 $result['href'] = $uri;
1165 $this->emit('afterBind', [$uri]);
1389 $uri = $ifCondition['uri'];
1407 $node = $this->tree->getNodeForPath($uri);
1423 …ew Exception\PreconditionFailed('Failed to find a valid token/etag combination for ' . $uri, 'If');