protected static function nodeToXpath(\DOMNode $domnode) {
		$dom = new \DOMDocument();
		$dom->formatOutput = true;
		$node = $dom->importNode($domnode, true);
		if($node instanceof \DOMElement)
			$dom->appendChild($node);
		return new \DOMXPath($dom);
	}