You are here

public function Translator::addCombination in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 vendor/symfony/css-selector/XPath/Translator.php \Symfony\Component\CssSelector\XPath\Translator::addCombination()

Parameters

string $combiner:

NodeInterface $xpath:

NodeInterface $combinedXpath:

Return value

XPathExpr

Throws

ExpressionErrorException

File

vendor/symfony/css-selector/XPath/Translator.php, line 220

Class

Translator
XPath expression translator interface.

Namespace

Symfony\Component\CssSelector\XPath

Code

public function addCombination($combiner, NodeInterface $xpath, NodeInterface $combinedXpath) {
  if (!isset($this->combinationTranslators[$combiner])) {
    throw new ExpressionErrorException(sprintf('Combiner "%s" not supported.', $combiner));
  }
  return call_user_func($this->combinationTranslators[$combiner], $this
    ->nodeToXPath($xpath), $this
    ->nodeToXPath($combinedXpath));
}