设置事件循环(在 FastAPI 启动时调用)
(self, loop: asyncio.AbstractEventLoop)
| 80 | self._loop: Optional[asyncio.AbstractEventLoop] = None |
| 81 | |
| 82 | def set_loop(self, loop: asyncio.AbstractEventLoop): |
| 83 | """设置事件循环(在 FastAPI 启动时调用)""" |
| 84 | self._loop = loop |
| 85 | |
| 86 | def get_loop(self) -> Optional[asyncio.AbstractEventLoop]: |
| 87 | """获取事件循环""" |
no outgoing calls
no test coverage detected