我们从Python开源项目中,提取了以下1个代码示例,用于说明如何使用tornado.web.py()。
def _load_ui_modules(self, modules): if type(modules) is types.ModuleType: self._load_ui_modules(dict((n, getattr(modules, n)) for n in dir(modules))) elif isinstance(modules, list): for m in modules: self._load_ui_modules(m) else: assert isinstance(modules, dict) for name, cls in modules.iteritems(): try: if issubclass(cls, UIModule): self.ui_modules[name] = cls except TypeError: pass # ????: ??? --> ????? # # ??: ????? # - wsgi.py # - WSGIApplication() # - self.__call__() ?? #