Function holochain::prelude::kitsune_p2p::dependencies::kitsune_p2p_types::dependencies::lair_keystore_api::dependencies::hc_seed_bundle::dependencies::rmpv::decode::value_ref::read_value_ref_with_max_depth
pub fn read_value_ref_with_max_depth<'a, R>(
rd: &mut R,
max_depth: usize
) -> Result<ValueRef<'a>, Error>where
R: BorrowRead<'a>,
Expand description
Attempts to read the data from the given reader until either a complete MessagePack value decoded or an error detected.
Returns either a non-owning ValueRef
, which borrows the buffer from the given reader or an
error.
See read_value_ref
for more information on how to use this function. This variant allows
you to specify the maximum recursion depth, if MAX_DEPTH
is too high.
Errors
Same as read_value_ref
, using the max_depth
parameter in place of
MAX_DEPTH
.