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

Method clear

graphlite/src/cache/result_cache.rs:524–531  ·  view source on GitHub ↗

Clear all cached results

(&self)

Source from the content-addressed store, hash-verified

522
523 /// Clear all cached results
524 pub fn clear(&self) {
525 self.l1_cache.write().unwrap().clear();
526 self.l2_cache.write().unwrap().clear();
527 *self.l1_current_memory.write().unwrap() = 0;
528 *self.l2_current_memory.write().unwrap() = 0;
529 *self.l1_lru.write().unwrap() = LRUTracker::new();
530 *self.l2_lru.write().unwrap() = LRUTracker::new();
531 }
532}
533
534/// Helper to create query cache key from query string and parameters

Callers 1

update_positionsMethod · 0.45

Calls 1

unwrapMethod · 0.80

Tested by

no test coverage detected