def get_view_env(self): #prepare local env local_env = {} #process before view call dispatch.call(self, 'prepare_view_env', local_env) local_env['application'] = __global__.application local_env['request'] = local.request local_env['response'] = local.response local_env['settings'] = __global__.settings env = Storage(self.env.to_dict()) env.update(local_env) return env
def get_env(self, env=None): e = Storage(self.env.copy()) if env: e.update(env) return e