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

Function read_bool

nodedb-query/src/msgpack_scan/reader.rs:360–366  ·  view source on GitHub ↗

Read a boolean from the value at `offset`.

(buf: &[u8], offset: usize)

Source from the content-addressed store, hash-verified

358
359/// Read a boolean from the value at `offset`.
360pub fn read_bool(buf: &[u8], offset: usize) -> Option<bool> {
361 match get(buf, offset)? {
362 TRUE => Some(true),
363 FALSE => Some(false),
364 _ => None,
365 }
366}
367
368/// Check if the value at `offset` is nil.
369pub fn read_null(buf: &[u8], offset: usize) -> bool {

Callers 5

read_value_as_stringFunction · 0.85
count_facet_fieldMethod · 0.85

Calls 1

getFunction · 0.85