Did I find the right examples for you? yes no

All Samples(16)  |  Call(16)  |  Derive(0)  |  Import(0)

        def putResource(env, resourcePath, value):
    monitor = getResourceMonitor(env)
    result = monitor.put(resourcePath, value, env)
    return result
        


src/w/h/whiff-1.1/whiff/resources/GAETreeStore.py   whiff(Download)
    #pr "got session password", (sesspassword, envpassword, passwordOk)
    if envcreator and envcreator!=sesscreator:
        gateway.putResource(env, creatorPath, envcreator)
        env["creatorNick"] = envcreator
    else:
        env["creatorNick"] = sesscreator
    if passwordOk:
        if envpassword and envpassword!=sesspassword:
            gateway.putResource(env, passwordPath, envpassword)
    else:
        #pr "putting blank password", (passwordPath, "")
        gateway.putResource(env, passwordPath, "")
        env["password"] = ""
 
    if not result:
        passwordPath = ["session", "item", "password"]
        gateway.putResource(env, passwordPath, "")
        whiffenv.cgiPut(env, "password", "")
        env["password"] = ""

src/w/h/whiff-1.1/whiff/middleware/checkProfile.py   whiff(Download)
        if profileValid:
            if storeSession:
                gateway.putResource(env, sessionResourcePath+[userVariable], user)
                gateway.putResource(env, sessionResourcePath+[passwordVariable], password)                
            # profile ok... success

src/w/h/whiff-1.1/whiff/middleware/newProfile.py   whiff(Download)
            if identity:
                # record the profile information in the session and environment
                gateway.putResource(env, sessionResourcePath+[userVariable], user)
                gateway.putResource(env, sessionResourcePath+[passwordVariable], password)
                env[userVariable] = user

src/w/h/whiff-1.1/whiff/resources/resourceAsDictionary.py   whiff(Download)
    def __setitem__(self, key, value):
        path = self.keyPath(key)
        env = self.env
        return gateway.putResource(env, path, value)
    def keys(self):

src/w/h/whiff-1.1/whiff/middleware/insertIfNeeded.py   whiff(Download)
            if needed:
                # the text is needed and not done: mark it as done and deliver the text
                gateway.putResource(env, donePath, True)
                return self.deliver_page(self.text, env, start_response)
        # if we get here, don't do anything and deliver empty string

src/w/h/whiff-1.1/whiff/middleware/skimpy.py   whiff(Download)
            captcha = str( numeric_hash((time.time(), cookievalue), secret) )
            #pr "setting captcha", captcha
            gateway.putResource(env, captchaPath, captcha)
            #pr "delivering image", captcha
            speckle = 0.3

src/w/h/whiff-1.1/whiff/middleware/png/ERdiagram.py   whiff(Download)
            spec = d.dumpList()
        # store the (adjusted) spec as a resource in case other component needs to use the value
        gateway.putResource(env, rulePath, spec)
        d.prepare()
        d.draw()

src/w/h/whiff-1.1/whiff/middleware/treeToDictionary.py   whiff(Download)
        if toResource is not None:
            # store dict at resource and return empty string
            gateway.putResource(env, toResource, outDict)
            return self.deliver_page("", env, start_response)
        else:

src/w/h/whiff-1.1/whiff/middleware/putResource.py   whiff(Download)
        else:
            new_value = self.param_value(self.value, env)
        gateway.putResource(env, resourcePathList, new_value)
        # deliver an empty page
        return self.deliver_page("", env, start_response)

src/w/h/whiff-1.1/whiff/middleware/profile.py   whiff(Download)
        #stats.print_callers() # verbose
        report = stream.getvalue()
        gateway.putResource(env, resourcePath, report)
        return self.deliver_page(page, env, start_response)
 

  1 | 2  Next