memory¶
- class litestar.stores.memory.MemoryStore[原始碼]¶
基底類別:
StoreIn memory, atomic, asynchronous key/value store.
- __init__() None[原始碼]¶
Initialize
MemoryStore
- async set(key: str, value: str | bytes, expires_in: int | timedelta | None = None) None[原始碼]¶
Set a value.
- async delete(key: str) None[原始碼]¶
Delete a value.
If no such key exists, this is a no-op.
- 參數:
key¶ -- Key of the value to delete