pub struct FsMemory { /* private fields */ }Expand description
Filesystem memory store backed by Markdown files.
Clone is cheap — clones share the same base path.
Implementations§
Trait Implementations§
Source§impl Memory for FsMemory
impl Memory for FsMemory
Source§fn set(
&self,
key: impl Into<String>,
value: impl Into<String>,
) -> Option<String>
fn set( &self, key: impl Into<String>, value: impl Into<String>, ) -> Option<String>
Set (upsert) a key-value pair. Returns the previous value if the key existed.
Source§fn remove(&self, key: &str) -> Option<String>
fn remove(&self, key: &str) -> Option<String>
Remove a key. Returns the removed value if it existed.
Source§fn store(
&self,
key: impl Into<String> + Send,
value: impl Into<String> + Send,
) -> impl Future<Output = Result<(), Error>> + Send
fn store( &self, key: impl Into<String> + Send, value: impl Into<String> + Send, ) -> impl Future<Output = Result<(), Error>> + Send
Store a key-value pair (async). Default delegates to
set.Auto Trait Implementations§
impl Freeze for FsMemory
impl RefUnwindSafe for FsMemory
impl Send for FsMemory
impl Sync for FsMemory
impl Unpin for FsMemory
impl UnsafeUnpin for FsMemory
impl UnwindSafe for FsMemory
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<M> Hook for M
impl<M> Hook for M
Source§fn on_build_agent(&self, config: AgentConfig) -> AgentConfig
fn on_build_agent(&self, config: AgentConfig) -> AgentConfig
Source§fn on_register_tools(
&self,
registry: &mut ToolRegistry,
) -> impl Future<Output = ()> + Send
fn on_register_tools( &self, registry: &mut ToolRegistry, ) -> impl Future<Output = ()> + Send
Called by
Runtime::new() to register tools into the shared registry. Read more