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

Function encode

nodedb-query/src/msgpack_scan/index.rs:123–125  ·  view source on GitHub ↗
(v: &serde_json::Value)

Source from the content-addressed store, hash-verified

121 use serde_json::json;
122
123 fn encode(v: &serde_json::Value) -> Vec<u8> {
124 nodedb_types::json_msgpack::json_to_msgpack(v).expect("encode")
125 }
126
127 #[test]
128 fn build_and_lookup() {

Callers 12

build_and_lookupFunction · 0.70
missing_fieldFunction · 0.70
empty_mapFunction · 0.70
small_doc_uses_flatFunction · 0.70
large_doc_uses_hashmapFunction · 0.70
not_a_mapFunction · 0.70
fuzz_truncated_buffersFunction · 0.70
fuzz_non_map_inputsFunction · 0.70

Calls 2

json_to_msgpackFunction · 0.50
expectMethod · 0.45

Tested by 12

build_and_lookupFunction · 0.56
missing_fieldFunction · 0.56
empty_mapFunction · 0.56
small_doc_uses_flatFunction · 0.56
large_doc_uses_hashmapFunction · 0.56
not_a_mapFunction · 0.56
fuzz_truncated_buffersFunction · 0.56
fuzz_non_map_inputsFunction · 0.56