nonebot2/website/versioned_docs/version-2.0.0/api/drivers/_lifespan.md

48 lines
553 B
Markdown
Raw Normal View History

2023-06-01 14:26:07 +08:00
# nonebot.drivers.\_lifespan
## _class_ `Lifespan()` {#Lifespan}
- **参数**
empty
### _method_ `on_startup(func)` {#Lifespan-on_startup}
- **参数**
- `func` (LIFESPAN_FUNC)
- **返回**
- LIFESPAN_FUNC
### _method_ `on_shutdown(func)` {#Lifespan-on_shutdown}
- **参数**
- `func` (LIFESPAN_FUNC)
- **返回**
- LIFESPAN_FUNC
### _async method_ `startup()` {#Lifespan-startup}
- **参数**
empty
- **返回**
- None
### _async method_ `shutdown()` {#Lifespan-shutdown}
- **参数**
empty
- **返回**
- None