Set the cookie path

@param string $path The cookie path
@return KHttpCookie
501780
public function setPath($path)
    {
        if(empty($path)) {
            $this->_path = '/';
        } else {
            $this->_path = $path;
        }

        return $this;
    }
1087334
public function setPath($path)
    {
        if (is_array($path)) {
            $this->path = '/' . implode('/', $path);
        } else {
            $this->path = (string) $path;
        }

        return $this;
    }
53270
public function createPath($path)
    {
        $current = $this->session->getRootNode();

        $segments = preg_split('#/#', $path, null, PREG_SPLIT_NO_EMPTY);
        foreach ($segments as $segment) {
            if ($current->hasNode($segment)) {
                $current = $current->getNode($segment);
            } else {
                $current = $current->addNode($segment);
                $current->addMixin('mix:referenceable');
                $current->setProperty('jcr:uuid', UUIDHelper::generateUUID());
            }
        }

        return $current;
    }
619538
function setPath($path = null)
    {
        if ($path === null)
            $path = array();

        // the associate array is useless
        $this->_pathSequence = array_values( (array) $path);
        return $this;
    }
28796
public function withPath(string $path): self
    {
        $this->assertPresent($path);

        if ($this->path === $path) {
            return $this;
        }

        $clone = clone $this;
        $clone->path = $path;

        return $clone;
    }
58823
public function setCommandersPath($path)
    {
        $path = str_replace(['\\' . '/'], DIRECTORY_SEPARATOR, $path);
        $path = rtrim($path, DIRECTORY_SEPARATOR) . DIRECTORY_SEPARATOR;

        if (is_dir($path)) {
            $this->commandersPath = $path;
        }

        return $this;
    }
1068061
public function setPath($path)
    {
        if (is_string($path)) {
            $array = explode('/', $path);
        } else if (is_array($path)) {
            $array = $path;
            $path = implode('/', $path);
        }

        return $this
            ->setDot('path.string', $path)
            ->setDot('path.array', $array);
    }
1243611
public function changeAvatarPath($path)
    {
        $this->avatar_url = $path;

        $this->raise(new AvatarChanged($this));

        return $this;
    }
353690
public function setPath(string $path): self
    {
        $realpath = realpath($path);
        if ($path && $path === $realpath) {
            $this->path = $path . DIRECTORY_SEPARATOR;
        }

        return $this;
    }
472218
public function setPath($path)
	{
		if($path !== false)
			$path = trim($path, '/');

		$this->setProperty('path', $path);

		return $this;
	}
1033281
public function setCookie($key, $value)
	{
		$this->cookies[$key] = $value;
		$this->updateCookieHeader();

		return $this;
	}
459277
public function setCoreSessionCookiePath($value)
    {
        $this->setFieldName('session_cookie_path');
        $this->loadObject(true);
        $this->setFieldValue($value);

        return $this;
    }
141932
public function setFileInfoFromPath($path)
    {
        $info = pathinfo($path);
        $this->dirname = array_key_exists('dirname', $info) ? $info['dirname'] : null;
        $this->basename = array_key_exists('basename', $info) ? $info['basename'] : null;
        $this->extension = array_key_exists('extension', $info) ? $info['extension'] : null;
        $this->filename = array_key_exists('filename', $info) ? $info['filename'] : null;

        if (file_exists($path) && is_file($path)) {
            $this->mime = finfo_file(finfo_open(FILEINFO_MIME_TYPE), $path);
        }

        return $this;
    }
439766
protected function _setCurrentPath($path)
    {
        if ($this->_skipRoot && is_dir($path)) {
            $this->_currentPath = $path.(substr($path, -1)!=DS?DS:'');
        } else {
            $this->_currentPath = dirname($path) . DS;
        }
        return $this;
    }
1115518
public function path($path = '')
    {
        $this->_sty->setTemplateDir($path);
        $this->root = $path;
        return $this;
    }
965962
public function setPath($path)
    {
        if (preg_match(self::PATTERN_MATCH_PATH, $path) !== 1) {
            throw new \InvalidArgumentException('"' . $path . '" is not valid path as part of a URI.', 1184071242);
        }

        $this->path = $path;
    }
277193
private function setPath($path)
    {
        $this->info['path'] = $this->info['file'] = $this->info['extension'] = $this->info['content'] = null;

        if ($this->getScheme() === 'data') {
            $this->info['content'] = $path;

            return;
        }

        $file = substr(strrchr($path, '/'), 1);

        if (strlen($file)) {
            $path = substr($path, 0, -strlen($file));

            if (preg_match('/(.*)\.([\w]+)$/', $file, $match)) {
                $this->info['file'] = rawurldecode($match[1]);
                $this->info['extension'] = $match[2];
            } else {
                $this->info['file'] = rawurldecode($file);
            }
        }

        $this->info['path'] = [];

        foreach (explode('/', $path) as $dir) {
            $dir = rawurldecode($dir);

            if ($dir !== '') {
                $this->info['path'][] = $dir;
            }
        }
    }