|
|
|
|
</code></pre><p>Returns:</p><h3 id="def-before-start-self-none" tabindex="-1"><a class="header-anchor" href="#def-before-start-self-none"><span> <em><strong>def</strong></em> <code>before_start(self) -> None</code></span></a></h3><p> 启动前</p><p>Returns:</p><h3 id="def-after-start-self-none" tabindex="-1"><a class="header-anchor" href="#def-after-start-self-none"><span> <em><strong>def</strong></em> <code>after_start(self) -> None</code></span></a></h3><p> 启动后</p><p>Returns:</p><h3 id="def-before-process-shutdown-self-none" tabindex="-1"><a class="header-anchor" href="#def-before-process-shutdown-self-none"><span> <em><strong>def</strong></em> <code>before_process_shutdown(self) -> None</code></span></a></h3><p> 停止前</p><p>Returns:</p><h3 id="def-after-shutdown-self-none" tabindex="-1"><a class="header-anchor" href="#def-after-shutdown-self-none"><span> <em><strong>def</strong></em> <code>after_shutdown(self) -> None</code></span></a></h3><p> 停止后</p><p>Returns:</p><h3 id="def-before-process-restart-self-none" tabindex="-1"><a class="header-anchor" href="#def-before-process-restart-self-none"><span> <em><strong>def</strong></em> <code>before_process_restart(self) -> None</code></span></a></h3><p> 重启前</p><p>Returns:</p><h3 id="def-after-restart-self-none" tabindex="-1"><a class="header-anchor" href="#def-after-restart-self-none"><span> <em><strong>def</strong></em> <code>after_restart(self) -> None</code></span></a></h3><p> 重启后</p><p>Returns:</p>`,73),r=[o];function a(c,l){return n(),s("div",null,r)}const p=e(t,[["render",a],["__file","lifespan.html.vue"]]),i=JSON.parse('{"path":"/en/dev/api/liteyuki/bot/lifespan.html","title":"liteyuki.bot.lifespan","lang":"en-US","frontmatter":{"title":"liteyuki.bot.lifespan","order":1,"icon":"laptop-code","category":"API","description":"def run_funcs(funcs: list[LIFESPAN_FUNC | PROCESS_LIFESPAN_FUNC]) -> None 运行函数 Args: Returns: class Lifespan def __init__(self) -> None 轻雪生命周期管理,启动、停止、重启 @staticmethod def run_f...","head":[["meta",{"property":"og:url","content":"https://vuepress-theme-hope-docs-demo.netlify.app/en/dev/api/liteyuki/bot/lifespan.html"}],["meta",{"property":"og:site_name","content":"LiteyukiBot"}],["meta",{"property":"og:title","content":"liteyuki.bot.lifespan"}],["meta",{"property":"og:description","content":"def run_funcs(funcs: list[LIFESPAN_FUNC | PROCESS_LIFESPAN_FUNC]) -> None 运行函数 Args: Returns: class Lifespan def __init__(self) -> None 轻雪生命周期管理,启动、停止、重启 @staticmethod def run_f..."}],["meta",{"property":"og:type","content":"article"}],["meta",{"property":"og:locale","content":"en-US"}],["meta",{"property":"og:updated_time","content":"2024-08-19T02:04:24.000Z"}],["meta",{"property":"article:modified_time","content":"2024-08-19T02:04:24.000Z"}],["script",{"type":"application/ld+json"},"{\\"@context\\":\\"https://schema.org\\",\\"@type\\":\\"Article\\",\\"headline\\":\\"liteyuki.bot.lifespan\\",\\"image\\":[\\"\\"],\\"dateModified\\":\\"2024-08-19T02:04:24.000Z\\",\\"author\\":[]}"]]},"headers":[{"level":3,"title":"def run_funcs(funcs: list[LIFESPAN_FUNC | PROCESS_LIFESPAN_FUNC]) -> None","slug":"def-run-funcs-funcs-list-lifespan-func-process-lifespan-func-none","link":"#def-run-funcs-funcs-list-lifespan-func-process-lifespan-func-none","children":[]},{"level":3,"title":"class Lifespan","slug":"class-lifespan","link":"#class-lifespan","children":[]},{"level":3,"title":"def __init__(self) -> None","slug":"def-init-self-none","link":"#def-init-self-none","children":[]},{"level":3,"title":"@staticmethod","slug":"staticmethod","link":"#staticmethod","children":[]},{"level":3,"title":"def run_funcs(funcs: list[LIFESPAN_FUNC | PROCESS_LIFESPAN_FUNC]) -> None","slug":"def-run-funcs-funcs-list-lifespan-func-process-lifespan-func-none-1","link":"#def-run-funcs-funcs-list-lifespan-func-process-lifespan-func-none-1","children":[]},{"level":3,"title":"def on_before_start(self, func: LIFESPAN_FUNC) -> LIFESPAN_FUNC","s
|