You are here

protected function FeedsExBase::prepareExpressions in Feeds extensible parsers 7

Same name and namespace in other branches
  1. 7.2 src/FeedsExBase.inc \FeedsExBase::prepareExpressions()

Prepares the expressions for parsing.

At this point we just remove empty expressions.

Return value

array A map of machine name to expression.

3 calls to FeedsExBase::prepareExpressions()
FeedsExBase::parseItems in src/FeedsExBase.inc
Performs the actual parsing.
FeedsExJmesPathLines::parseItems in src/FeedsExJmesPathLines.inc
Performs the actual parsing.
FeedsExJsonPathLines::parseItems in src/FeedsExJsonPathLines.inc
Performs the actual parsing.

File

src/FeedsExBase.inc, line 246
Contains FeedsExBase.

Class

FeedsExBase
The Feeds extensible parser.

Code

protected function prepareExpressions() {
  $expressions = array();
  foreach ($this->config['sources'] as $machine_name => $source) {
    if (strlen($source['value'])) {
      $expressions[$machine_name] = $source['value'];
    }
  }
  return $expressions;
}