public class NamespaceContextImpl extends Object implements NamespaceContext, NamespaceResolver
| Constructor and Description |
|---|
NamespaceContextImpl(NamespaceResolver resolver)
Constructor: wrap a Saxon NamespaceResolver as a JAXP NamespaceContext
|
| Modifier and Type | Method and Description |
|---|---|
String |
getNamespaceURI(String prefix)
Implement the JAXP getNamespaceURI() method in terms of the Saxon-specific methods
|
String |
getPrefix(String uri)
Get the prefix bound to a particular namespace URI, if there is one, or null if not (JAXP method)
|
Iterator |
getPrefixes(String uri)
Get all the prefixes mapped to a given namespace URI (JAXP method)
|
String |
getURIForPrefix(String prefix,
boolean useDefault)
Get the namespace URI corresponding to a given prefix.
|
Iterator<String> |
iteratePrefixes()
Get an iterator over all the prefixes declared in this namespace context.
|
public NamespaceContextImpl(NamespaceResolver resolver)
resolver - the Saxon NamespaceResolverpublic String getURIForPrefix(String prefix, boolean useDefault)
getURIForPrefix in interface NamespaceResolverprefix - the namespace prefixuseDefault - true if the default namespace is to be used when the
prefix is ""public Iterator<String> iteratePrefixes()
iteratePrefixes in interface NamespaceResolverpublic String getNamespaceURI(String prefix)
getNamespaceURI in interface NamespaceContextprefix - a namespace prefixpublic String getPrefix(String uri)
getPrefix in interface NamespaceContexturi - the namespace URIpublic Iterator getPrefixes(String uri)
getPrefixes in interface NamespaceContexturi - the namespace URICopyright (c) 2004-2013 Saxonica Limited. All rights reserved.