class FeedsExJsonPathParserFlow in Feeds extensible parsers 7
Wraps the Flow JSONPath implementation.
Hierarchy
- class \FeedsExJsonPathParserFlow implements FeedsExJsonPathParserInterface
Expanded class hierarchy of FeedsExJsonPathParserFlow
File
- src/
FeedsExJsonPath.inc, line 178 - Contains FeedsExJsonPath.
View source
class FeedsExJsonPathParserFlow implements FeedsExJsonPathParserInterface {
/**
* {@inheritdoc}
*/
public function search(array $data, $expression) {
// Use class string so that PHP 5.2 doesn't complain.
$class = 'Flow\\JSONPath\\JSONPath';
$json_path = new $class($data);
return $json_path
->find($expression)
->data();
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
FeedsExJsonPathParserFlow:: |
public | function |
Searches an array via JSONPath. Overrides FeedsExJsonPathParserInterface:: |