code: public String getNamespaceURI(String qname, boolean isElement)
      {
          String uri = EMPTYSTRING;
          int col = qname.lastIndexOf(':');
          final String prefix = (col > 0) ? qname.substring(0, col) : EMPTYSTRING;
  
          if (!EMPTYSTRING.equals(prefix) || isElement)
          {
              if (m_prefixMap != null)
              {
                  uri = m_prefixMap.lookupNamespace(prefix);
                  if (uri == null && !prefix.equals(XMLNS_PREFIX))
                  {
                      throw new RuntimeException(
                          Utils.messages.createMessage(
                              MsgKey.ER_NAMESPACE_PREFIX,
                              new Object[] { qname.substring(0, col) }  ));
                  }
              }
          }
          return uri;
      }
docs: Returns the URI of an element or attribute. Note that default namespaces
  do not apply directly to attributes.
  @param qname a qualified name
  @param isElement true if the qualified name is the name of
  an element.
  @return returns the namespace URI associated with the qualified name.