You are here

protected function Xml::getXmlDocumentPath in Views XML Backend 8

Returns the path to the XML file after token substitution.

Parameters

\Drupal\views\ViewExecutable $view: The view.

Return value

string The file path or URL.

1 call to Xml::getXmlDocumentPath()
Xml::doExecute in src/Plugin/views/query/Xml.php
Performs the actual view execution.

File

src/Plugin/views/query/Xml.php, line 480
Contains \Drupal\views_xml_backend\Plugin\views\query\Xml.

Class

Xml
Views query plugin for an XML query.

Namespace

Drupal\views_xml_backend\Plugin\views\query

Code

protected function getXmlDocumentPath(ViewExecutable $view) {

  // This should be safe from malicious user input since the URL is internal
  // and an invalid one will just produce a download error.
  return strtr($this->options['xml_file'], $view
    ->getDisplay()
    ->getArgumentsTokens());
}