MCPcopy Create free account
hub / github.com/GraphLite-AI/GraphLite / get_graph_mut

Method get_graph_mut

graphlite/src/storage/multi_graph.rs:70–79  ·  view source on GitHub ↗

Get a mutable reference to a graph

(&self, name: &str)

Source from the content-addressed store, hash-verified

68
69 /// Get a mutable reference to a graph
70 pub fn get_graph_mut(&self, name: &str) -> Result<Option<GraphCache>, StorageError> {
71 debug!("Getting mutable graph: {}", name);
72
73 let graphs = self
74 .graphs
75 .read()
76 .map_err(|e| StorageError::LockError(format!("Failed to acquire read lock: {}", e)))?;
77
78 Ok(graphs.get(name).cloned())
79 }
80
81 /// Check if a graph exists
82 pub fn has_graph(&self, name: &str) -> bool {

Callers

nothing calls this directly

Calls 1

getMethod · 0.45

Tested by

no test coverage detected