public function getNamespaceMappings()
	{
		$dom = (new XmlDocumentBuilder())->buildDocument($this);
		$xpath = new \DOMXPath($dom);
		
		$namespaces = [];
		
		foreach($xpath->query('namespace::*', $dom->documentElement) as $result)
		{
			$namespaces[(string)$result->prefix] = (string)$result->nodeValue;
		}
		
		return $namespaces;
	}
public function getNamespaceMappings()
	{
		$dom = (new XmlDocumentBuilder())->buildDocument($this);
		$xpath = new \DOMXPath($dom);
		
		$namespaces = [];
		
		foreach($xpath->query('namespace::*', $dom->documentElement) as $result)
		{
			$namespaces[(string)$result->prefix] = (string)$result->nodeValue;
		}
		
		return $namespaces;
	}
public function getNamespaceMappings ( ) { $ dom = ( new XmlDocumentBuilder ( ) ) -> buildDocument ( $ this ) ; $ xpath = new \ DOMXPath ( $ dom ) ; $ namespaces = [ ] ; foreach ( $ xpath -> query ( 'namespace::*' , $ dom -> documentElement ) as $ result ) { $ namespaces [ ( string ) $ result -> prefix ] = ( string ) $ result -> nodeValue ; } return $ namespaces ; }
Get a map of namespaces prefix - URI mappings of the current node, prefixes are keys.

@return array<string, string>
Get a map of namespaces prefix - URI mappings of the current node prefixes are keys .