Struct jsonpath_rust::JsonPathFinder[][src]

pub struct JsonPathFinder { /* fields omitted */ }

The base structure conjuncting the json instance and jsonpath instance

Implementations

impl JsonPathFinder[src]

pub fn new(json: Value, path: JsonPath) -> Self[src]

creates a new instance of [JsonPathFinder]

pub fn set_path(&mut self, path: JsonPath)[src]

updates a path with a new one

pub fn set_json(&mut self, json: Value)[src]

updates a json with a new one

pub fn set_json_str(&mut self, json: &str) -> Result<(), String>[src]

updates a json from string and therefore can be some parsing errors

pub fn set_path_str(&mut self, path: &str) -> Result<(), String>[src]

updates a path from string and therefore can be some parsing errors

pub fn from_str(json: &str, path: &str) -> Result<Self, String>[src]

create a new instance from string and therefore can be some parsing errors

pub fn instance(&self) -> Box<dyn Path<'_, Data = Value> + '_>[src]

creates an instance to find a json slice from the json

pub fn find(&self) -> Vec<&Value>[src]

finds a slice of data in the set json. The result is a vector of references to the incoming structure.

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.