pub struct Storage { /* private fields */ }Implementations§
Source§impl Storage
impl Storage
pub fn list_directory_bookmarks(&self) -> Result<Vec<DirectoryBookmarkRecord>>
pub fn upsert_directory_bookmark( &self, path: &Path, display_name: Option<&str>, ) -> Result<DirectoryBookmarkRecord>
pub fn remove_directory_bookmark(&self, path: &Path) -> Result<()>
pub fn list_directory_history( &self, limit: usize, ) -> Result<Vec<DirectoryHistoryRecord>>
pub fn record_directory_usage( &self, path: &Path, ) -> Result<DirectoryHistoryRecord>
Source§impl Storage
impl Storage
pub fn append_event( &self, event_type: &str, runtime_id: Option<&str>, thread_id: Option<&str>, payload: &Value, ) -> Result<PersistedEvent>
pub fn replay_events_after(&self, last_seq: i64) -> Result<Vec<PersistedEvent>>
pub fn load_thread_events(&self, thread_id: &str) -> Result<Vec<PersistedEvent>>
pub fn save_mobile_session_ack( &self, device_id: &str, last_ack_seq: i64, ) -> Result<()>
pub fn get_mobile_session_ack(&self, device_id: &str) -> Result<Option<i64>>
pub fn latest_event_seq(&self) -> Result<i64>
Source§impl Storage
impl Storage
pub fn upsert_bridge_management_task( &self, task: &BridgeManagementTask, ) -> Result<()>
pub fn get_bridge_management_task( &self, task_id: &str, ) -> Result<Option<BridgeManagementTask>>
pub fn latest_bridge_management_task( &self, ) -> Result<Option<BridgeManagementTask>>
pub fn active_bridge_management_task( &self, ) -> Result<Option<BridgeManagementTask>>
Source§impl Storage
impl Storage
pub fn put_pending_request( &self, request: &PendingServerRequestRecord, ) -> Result<()>
pub fn get_pending_request( &self, request_id: &str, ) -> Result<Option<PendingServerRequestRecord>>
pub fn list_pending_requests(&self) -> Result<Vec<PendingServerRequestRecord>>
pub fn remove_pending_request(&self, request_id: &str) -> Result<()>
pub fn clear_pending_requests(&self) -> Result<()>
Source§impl Storage
impl Storage
pub fn ensure_primary_runtime( &self, codex_home: Option<String>, codex_binary: String, ) -> Result<RuntimeRecord>
pub fn list_runtimes(&self) -> Result<Vec<RuntimeRecord>>
pub fn get_runtime(&self, runtime_id: &str) -> Result<Option<RuntimeRecord>>
pub fn upsert_runtime(&self, runtime: &RuntimeRecord) -> Result<()>
pub fn remove_runtime(&self, runtime_id: &str) -> Result<()>
Source§impl Storage
impl Storage
pub fn upsert_thread_index(&self, thread: &ThreadSummary) -> Result<()>
pub fn get_thread_index(&self, thread_id: &str) -> Result<Option<ThreadSummary>>
pub fn list_thread_index( &self, directory_prefix: Option<&str>, runtime_id: Option<&str>, archived: Option<bool>, search_term: Option<&str>, ) -> Result<Vec<ThreadSummary>>
pub fn save_thread_note( &self, thread_id: &str, note: Option<&str>, ) -> Result<()>
pub fn set_thread_archived(&self, thread_id: &str, archived: bool) -> Result<()>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Storage
impl RefUnwindSafe for Storage
impl Send for Storage
impl Sync for Storage
impl Unpin for Storage
impl UnsafeUnpin for Storage
impl UnwindSafe for Storage
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