BotStateMemoryScope Klasa
Konstruktor
BotStateMemoryScope(bot_state_type: Type[BotState], name: str)
Parametry
| Nazwa | Opis |
|---|---|
|
bot_state_type
Wymagane
|
|
|
name
Wymagane
|
|
Metody
| get_memory | |
| load | |
| save_changes | |
| set_memory |
get_memory
get_memory(dialog_context: DialogContext) -> object
Parametry
| Nazwa | Opis |
|---|---|
|
dialog_context
Wymagane
|
|
load
async load(dialog_context: DialogContext, force: bool = False)
Parametry
| Nazwa | Opis |
|---|---|
|
dialog_context
Wymagane
|
|
|
force
|
Domyślna wartość: False
|
save_changes
async save_changes(dialog_context: DialogContext, force: bool = False)
Parametry
| Nazwa | Opis |
|---|---|
|
dialog_context
Wymagane
|
|
|
force
|
Domyślna wartość: False
|
set_memory
set_memory(dialog_context: DialogContext, memory: object)
Parametry
| Nazwa | Opis |
|---|---|
|
dialog_context
Wymagane
|
|
|
memory
Wymagane
|
|