Class DocumentNamespaceResolver

  • All Implemented Interfaces:
    javax.xml.namespace.NamespaceContext

    public class DocumentNamespaceResolver
    extends java.lang.Object
    implements javax.xml.namespace.NamespaceContext
    Simple namespace resolver that deflects namespaceURI resolution to the document.
    Author:
    David Schlenk
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getNamespaceURI​(java.lang.String prefix)  
      java.lang.String getPrefix​(java.lang.String namespaceURI)  
      java.util.Iterator getPrefixes​(java.lang.String namespaceURI)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • DocumentNamespaceResolver

        public DocumentNamespaceResolver​(org.w3c.dom.Document document)
    • Method Detail

      • getNamespaceURI

        public java.lang.String getNamespaceURI​(java.lang.String prefix)
        Specified by:
        getNamespaceURI in interface javax.xml.namespace.NamespaceContext
      • getPrefix

        public java.lang.String getPrefix​(java.lang.String namespaceURI)
        Specified by:
        getPrefix in interface javax.xml.namespace.NamespaceContext
      • getPrefixes

        public java.util.Iterator getPrefixes​(java.lang.String namespaceURI)
        Specified by:
        getPrefixes in interface javax.xml.namespace.NamespaceContext