private static exportNamespaceDeclarations ( PHPCR\NamespaceRegistryInterface $ns, resource $stream ) | ||
$ns | PHPCR\NamespaceRegistryInterface | the registry with the namespaces to export |
$stream | resource | the output stream to write the namespaces to |
private static function exportNamespaceDeclarations(NamespaceRegistryInterface $ns, $stream)
{
foreach ($ns as $key => $uri) {
if (!empty($key)) {
// no ns declaration for empty namespace
fwrite($stream, " xmlns:{$key}=\"{$uri}\"");
}
}
}