pub struct HistoryManager { /* private fields */ }Implementations§
Source§impl HistoryManager
impl HistoryManager
pub fn new(path: impl AsRef<Path>) -> Result<Self, MemoryError>
pub fn add_history( &self, memory_id: Uuid, previous_content: Option<String>, new_content: String, event: EventType, timestamp: DateTime<Utc>, user_id: Option<String>, agent_id: Option<String>, run_id: Option<String>, ) -> Result<(), MemoryError>
pub fn get_history( &self, memory_id: Uuid, ) -> Result<Vec<HistoryEntry>, MemoryError>
pub fn reset(&self) -> Result<(), MemoryError>
Auto Trait Implementations§
impl Freeze for HistoryManager
impl RefUnwindSafe for HistoryManager
impl Send for HistoryManager
impl Sync for HistoryManager
impl Unpin for HistoryManager
impl UnwindSafe for HistoryManager
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more