MCPcopy Create free account
hub / github.com/Vector35/binaryninja-api / value

Method value

rust/src/database/kvs.rs:45–50  ·  view source on GitHub ↗

Get the value for a single key

(&self, key: S)

Source from the content-addressed store, hash-verified

43
44 /// Get the value for a single key
45 pub fn value<S: BnStrCompatible>(&self, key: S) -> Option<DataBuffer> {
46 let key_raw = key.into_bytes_with_nul();
47 let key_ptr = key_raw.as_ref().as_ptr() as *const c_char;
48 let result = unsafe { BNGetKeyValueStoreBuffer(self.handle.as_ptr(), key_ptr) };
49 NonNull::new(result).map(|_| DataBuffer::from_raw(result))
50 }
51
52 /// Set the value for a single key
53 pub fn set_value<S: BnStrCompatible>(&self, key: S, value: &DataBuffer) -> bool {

Callers 15

AddExternalLocationMethod · 0.45
SetTargetAddressMethod · 0.45
SetTargetSymbolMethod · 0.45
GetExprTextMethod · 0.45
GetExprTextInternalMethod · 0.45
to_hashmapMethod · 0.45
mainFunction · 0.45
PerformInitialLoadMethod · 0.45

Calls 3

into_bytes_with_nulMethod · 0.80
mapMethod · 0.80
as_refMethod · 0.45

Tested by

no test coverage detected