Crate sql_json_path

source ·
Expand description

SQL/JSON Path implementation in Rust.

Features

Usage

use serde_json::{json, Value};
use sql_json_path::JsonPath;

let json = json!({"a": 1});
let path = JsonPath::new("$.a").unwrap();

let nodes = path.query(&json).unwrap();
assert_eq!(nodes.len(), 1);
assert_eq!(nodes[0].to_string(), "1");

Modules

  • Abstraction over JSON values.

Structs

Enums

  • The error type returned when evaluating a JSON path.