[−][src]Function json_digest::selective_digest_json
pub fn selective_digest_json(
json_value: &Value,
keep_paths_str: &str
) -> Result<String>
Convenience function to transform a JSON value into a (partially) masked JSON value. Only subtrees matching the provided JSON path pattern will be kept, all other subtrees will be masked.
Nearly equivalent to mask_json_subtree(&json_value, split_alternatives(keep_paths_str))
,
but always returns a string, not a serde_json::Value
.