public class RegistryNamespaceResolver extends Object implements NamespaceResolver
Constructor and Description |
---|
RegistryNamespaceResolver(javax.jcr.NamespaceRegistry registry)
Creates a new namespace resolver based on the given namespace registry.
|
public RegistryNamespaceResolver(javax.jcr.NamespaceRegistry registry)
registry
- namespace registrypublic String getPrefix(String uri) throws javax.jcr.NamespaceException
NamespaceResolver
getPrefix
in interface NamespaceResolver
uri
- namespace URIjavax.jcr.NamespaceException
- if the URI is unknown.public String getURI(String prefix) throws javax.jcr.NamespaceException
NamespaceResolver
getURI
in interface NamespaceResolver
prefix
- namespace prefixjavax.jcr.NamespaceException
- if the prefix is unknown.Copyright © 2004-2020 The Apache Software Foundation. All Rights Reserved.