|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sf.saxon.pull.NamespaceContextImpl
public class NamespaceContextImpl
This class bridges between the JAXP 1.3 NamespaceContext interface and Saxon's equivalent NamespaceResolver interface. It allows any implementation of the Saxon NamespaceResolver to be wrapped as a JAXP NamespaceContext.
Constructor Summary | |
---|---|
NamespaceContextImpl(NamespaceResolver resolver)
Constructor: wrap a Saxon NamespaceResolver as a JAXP NamespaceContext |
Method Summary | |
---|---|
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 |
iteratePrefixes()
Get an iterator over all the prefixes declared in this namespace context. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public NamespaceContextImpl(NamespaceResolver resolver)
resolver
- the Saxon NamespaceResolverMethod Detail |
---|
public String getURIForPrefix(String prefix, boolean useDefault)
getURIForPrefix
in interface NamespaceResolver
prefix
- the namespace prefixuseDefault
- true if the default namespace is to be used when the
prefix is ""
public Iterator iteratePrefixes()
iteratePrefixes
in interface NamespaceResolver
public String getNamespaceURI(String prefix)
getNamespaceURI
in interface NamespaceContext
prefix
- a namespace prefix
public String getPrefix(String uri)
getPrefix
in interface NamespaceContext
uri
- the namespace URI
public Iterator getPrefixes(String uri)
getPrefixes
in interface NamespaceContext
uri
- the namespace URI
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |