MCPcopy Create free account
hub / github.com/NodeDB-Lab/nodedb / lookup

Function lookup

nodedb/src/fail_point.rs:56–62  ·  view source on GitHub ↗

Look up the installed action for a fail point (None if not set).

(name: &str)

Source from the content-addressed store, hash-verified

54
55 /// Look up the installed action for a fail point (None if not set).
56 pub fn lookup(name: &str) -> Option<FailAction> {
57 REGISTRY
58 .lock()
59 .unwrap_or_else(|p| p.into_inner())
60 .get(name)
61 .cloned()
62 }
63
64 /// Evaluate the installed action for a fail point. Used by the
65 /// `fail_point!` macro; not intended to be called directly.

Callers 1

evalFunction · 0.85

Calls 2

lockMethod · 0.80
getMethod · 0.45

Tested by

no test coverage detected