Struct jmespath::Expression
[−]
[src]
pub struct Expression {
// some fields omitted
}A compiled JMESPath expression.
Methods
impl Expression[src]
fn new(expression: &str) -> Result<Expression, Error>
Creates a new JMESPath expression from an expression string.
fn with_fn_dispatcher(expression: &str, fn_dispatcher: Arc<FnDispatcher>) -> Result<Expression, Error>
Creates a new JMESPath expression using a custom tree interpreter. Customer interpreters may be desired when you wish to utilize custom JMESPath functions in your expressions.
fn search<T: Serialize>(&self, data: T) -> SearchResult
Returns the result of searching Serde data with the compiled expression.
fn search_variable(&self, data: &RcVar) -> SearchResult
Returns the result of searching a JMESPath variable with the compiled expression.
NOTE: This specific method could eventually be removed once specialization lands in Rust. See https://github.com/rust-lang/rfcs/pull/1210
fn as_str(&self) -> &str
Returns the JMESPath expression from which the Expression was compiled.
fn as_ast(&self) -> &Ast
Returns the AST of the parsed JMESPath expression.
Trait Implementations
impl Display for Expression[src]
impl Debug for Expression[src]
impl PartialEq for Expression[src]
Equality comparison is based on the original string.