pub trait StateStore: Send + Sync {
// Required methods
fn get(&self, node_id: &str) -> Result<Option<Arc<Value>>>;
fn set(&self, node_id: &str, state: Value) -> Result<()>;
fn remove(&self, node_id: &str) -> Result<()>;
fn clear(&self) -> Result<()>;
fn keys(&self) -> Result<Vec<String>>;
}Expand description
Storage for trained filter states, keyed by node id.
Implementations must be Send + Sync and use interior mutability so
the store can be shared (via Arc) across the executor and the
graph session.
Required Methods§
Sourcefn get(&self, node_id: &str) -> Result<Option<Arc<Value>>>
fn get(&self, node_id: &str) -> Result<Option<Arc<Value>>>
Fetch the state for node_id, if present.