API Reference
Module Attributes
__file__ =
'C:\\Documents and Settings\\James\\Desktop\\PythonWeb\\bricks\\bricks\\middleware\\rename.pyc'
__name__ =
'bricks.middleware.rename'
Classes
class Renamedef __call__(self, environ, start_response)[show source]C:\Documents and Settings\James\Desktop\PythonWeb\bricks\bricks\middleware\rename.py 8: def __call__(self, environ, start_response): 9: #x = environ.keys() 10: #x.sort() 11: #raise Exception(x) 12: for k,v in self.dict.items(): 13: if v in self.dict.keys(): 14: raise Exception('Key %s already exists'%v) 15: environ[v] = environ[k] 16: del environ[k] 17: return self.application(environ, start_response)def __init__(self, application, dict)[show source]C:\Documents and Settings\James\Desktop\PythonWeb\bricks\bricks\middleware\rename.py 4: def __init__(self, application, dict): 5: self.dict = dict 6: self.application = application