pub struct SessionStore { /* private fields */ }Implementations§
Source§impl SessionStore
impl SessionStore
pub fn open(path: &Path) -> Result<Self, Error>
pub fn create_session(&self, model: &str, cwd: &Path) -> Result<Session, Error>
pub fn update_title(&self, id: &str, title: &str) -> Result<(), Error>
pub fn save_messages( &self, session_id: &str, messages: &[Message], ) -> Result<(), Error>
pub fn load_messages(&self, session_id: &str) -> Result<Vec<Message>, Error>
pub fn session_exists(&self, session_id: &str) -> Result<bool, Error>
pub fn list_sessions(&self, limit: usize) -> Result<Vec<SessionSummary>, Error>
pub fn delete_session(&self, id: &str) -> Result<(), Error>
Trait Implementations§
Source§impl SessionPersistence for SessionStore
impl SessionPersistence for SessionStore
Auto Trait Implementations§
impl !Freeze for SessionStore
impl RefUnwindSafe for SessionStore
impl Send for SessionStore
impl Sync for SessionStore
impl Unpin for SessionStore
impl UnsafeUnpin for SessionStore
impl UnwindSafe for SessionStore
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