Did I find the right examples for you? yes no

All Samples(6)  |  Call(6)  |  Derive(0)  |  Import(0)
Append segments to URI.

Example: joinUri("/a/b", "c", "d")

        def joinUri(uri, *segments):
    """Append segments to URI.
    
    Example: joinUri("/a/b", "c", "d")
    """
    sub = "/".join(segments)
    if not sub:
        return uri
    return uri.rstrip("/") + "/" + sub
        


src/w/s/WsgiDAV-1.1.0/wsgidav/fs_dav_provider.py   WsgiDAV(Download)
        fp = os.path.join(self._filePath, name.decode("utf8"))
#        name = name.encode("utf8")
        path = util.joinUri(self.path, name)
        if os.path.isdir(fp):
            res = FolderResource(path, self.environ, fp)
        if self.provider.readonly:
            raise DAVError(HTTP_FORBIDDEN)
        path = util.joinUri(self.path, name)
        fp = self.provider._locToFilePath(path)
        f = open(fp, "wb")
        if self.provider.readonly:
            raise DAVError(HTTP_FORBIDDEN)
        path = util.joinUri(self.path, name)
        fp = self.provider._locToFilePath(path)
        os.mkdir(fp)

src/w/s/wsgidav-HEAD/wsgidav/fs_dav_provider.py   wsgidav(Download)
        fp = os.path.join(self._filePath, name.decode("utf8"))
#        name = name.encode("utf8")
        path = util.joinUri(self.path, name)
        if os.path.isdir(fp):
            res = FolderResource(path, self.environ, fp)
        if self.provider.readonly:
            raise DAVError(HTTP_FORBIDDEN)
        path = util.joinUri(self.path, name)
        fp = self.provider._locToFilePath(path)
        f = open(fp, "wb")
        if self.provider.readonly:
            raise DAVError(HTTP_FORBIDDEN)
        path = util.joinUri(self.path, name)
        fp = self.provider._locToFilePath(path)
        os.mkdir(fp)