Documentation

AstRuntime
in package

Uses an external tree visitor to interpret an AST.

Table of Contents

$cache  : mixed
$cachedCount  : mixed
$interpreter  : mixed
$parser  : mixed
__construct()  : mixed
__invoke()  : mixed
Returns data from the provided input that matches a given JMESPath expression.

Properties

Methods

__construct()

public __construct([Parser $parser = null ][, callable $fnDispatcher = null ]) : mixed
Parameters
$parser : Parser = null
$fnDispatcher : callable = null
Return values
mixed

__invoke()

Returns data from the provided input that matches a given JMESPath expression.

public __invoke(string $expression, mixed $data) : mixed
Parameters
$expression : string

JMESPath expression to evaluate

$data : mixed

Data to search. This data should be data that is similar to data returned from json_decode using associative arrays rather than objects.

Return values
mixed

Returns the matching data or null

Search results