MCPcopy Create free account
hub / github.com/apache/datafusion / remove

Method remove

datafusion/execution/src/cache/list_files_cache.rs:286–293  ·  view source on GitHub ↗

Removes an entry from the cache and returns it, if it exists.

(&mut self, k: &TableScopedPath)

Source from the content-addressed store, hash-verified

284
285 /// Removes an entry from the cache and returns it, if it exists.
286 fn remove(&mut self, k: &TableScopedPath) -> Option<CachedFileList> {
287 if let Some(entry) = self.lru_queue.remove(k) {
288 self.memory_used -= entry.size_bytes;
289 Some(entry.metas)
290 } else {
291 None
292 }
293 }
294
295 /// Returns the number of entries currently cached.
296 fn len(&self) -> usize {

Callers 5

getMethod · 0.45
contains_keyMethod · 0.45
drop_table_entriesMethod · 0.45
test_basic_operationsFunction · 0.45
test_memory_trackingFunction · 0.45

Calls

no outgoing calls

Tested by 2

test_basic_operationsFunction · 0.36
test_memory_trackingFunction · 0.36