mirror of
https://github.com/LiteyukiStudio/LiteyukiBot.git
synced 2025-07-27 22:40:55 +00:00
📝 修复生成文档中self多出类型注解的问题,修复__init__丢失的问题
This commit is contained in:
@ -9,11 +9,19 @@ category: API
|
||||
|
||||
|
||||
|
||||
###   ***def*** `__init__(self, active: Channel[Any], passive: Channel[Any], channel_deliver_active: Channel[Channel[Any]], channel_deliver_passive: Channel[tuple[str, dict]]) -> None`
|
||||
|
||||
 
|
||||
|
||||
### ***class*** `ProcessManager`
|
||||
|
||||
进程管理器
|
||||
|
||||
###   ***def*** `start(self: Any, name: str) -> None`
|
||||
###   ***def*** `__init__(self, lifespan: 'Lifespan') -> None`
|
||||
|
||||
 
|
||||
|
||||
###   ***def*** `start(self, name: str) -> None`
|
||||
|
||||
 开启后自动监控进程,并添加到进程字典中
|
||||
|
||||
@ -23,11 +31,11 @@ Args:
|
||||
|
||||
Returns:
|
||||
|
||||
###   ***def*** `start_all(self: Any) -> None`
|
||||
###   ***def*** `start_all(self) -> None`
|
||||
|
||||
 启动所有进程
|
||||
|
||||
###   ***def*** `add_target(self: Any, name: str, target: TARGET_FUNC, args: tuple, kwargs: Any) -> None`
|
||||
###   ***def*** `add_target(self, name: str, target: TARGET_FUNC, args: tuple, kwargs: Any) -> None`
|
||||
|
||||
 添加进程
|
||||
|
||||
@ -41,11 +49,11 @@ Args:
|
||||
|
||||
kwargs: 进程函数关键字参数,通常会默认传入chan_active和chan_passive
|
||||
|
||||
###   ***def*** `join_all(self: Any) -> None`
|
||||
###   ***def*** `join_all(self) -> None`
|
||||
|
||||
 
|
||||
|
||||
###   ***def*** `terminate(self: Any, name: str) -> None`
|
||||
###   ***def*** `terminate(self, name: str) -> None`
|
||||
|
||||
 终止进程并从进程字典中删除
|
||||
|
||||
@ -57,11 +65,11 @@ Args:
|
||||
|
||||
Returns:
|
||||
|
||||
###   ***def*** `terminate_all(self: Any) -> None`
|
||||
###   ***def*** `terminate_all(self) -> None`
|
||||
|
||||
 
|
||||
|
||||
###   ***def*** `is_process_alive(self: Any, name: str) -> bool`
|
||||
###   ***def*** `is_process_alive(self, name: str) -> bool`
|
||||
|
||||
 检查进程是否存活
|
||||
|
||||
|
Reference in New Issue
Block a user