public function FeedsSource::preview in Feeds 8.2
Preview = fetch and parse a feed.
Return value
FeedsParserResult object.
Throws
Throws Exception if an error occurs when fetching or parsing.
File
- lib/
Drupal/ feeds/ FeedsSource.php, line 105 - Definition of FeedsSourceInterface and FeedsSource class.
Class
- FeedsSource
- This class encapsulates a source of a feed. It stores where the feed can be found and how to import it.
Namespace
Drupal\feedsCode
public function preview() {
$result = $this->importer->fetcher
->fetch($this);
$result = $this->importer->parser
->parse($this, $result);
module_invoke_all('feeds_after_parse', $this, $result);
return $result;
}