@Deprecated public void addPrefixNSMapping(String prefix,String nsURI){
  if (nsURI.length() == 0) {
    throw new IllegalArgumentException("Cannot map empty string URI");
  }
  if (prefix.length() == 0) {
    throw new IllegalArgumentException("Cannot map empty string prefix");
  }
  if (prefix.equals(NO_NS_PREFIX)) {
    throw new IllegalArgumentException("The prefix: " + prefix + " cannot be registered, it's reserved for special internal use.");
  }
  if (prefixToNamespaceURILookup.containsKey(prefix)) {
    throw new IllegalArgumentException("The prefix: '" + prefix + "' was repeated. This is illegal.");
  }
  if (namespaceURIToPrefixLookup.containsKey(nsURI)) {
    throw new IllegalArgumentException("The namespace URI: " + nsURI + " cannot be mapped to 2 different prefixes.");
  }
  if (prefix.equals(DEFAULT_NAMESPACE_PREFIX)) {
    this.defaultNS=nsURI;
  }
 else {
    prefixToNamespaceURILookup.put(prefix,nsURI);
    namespaceURIToPrefixLookup.put(nsURI,prefix);
  }
}

@ Deprecated public void addPrefixNSMapping ( String prefix , String nsURI ) { if ( nsURI . length ( ) == 0 ) { throw new IllegalArgumentException ( "Cannot map empty string URI" ) ; } if ( prefix . length ( ) == 0 ) { throw new IllegalArgumentException ( "Cannot map empty string prefix" ) ; } if ( prefix . equals ( NO_NS_PREFIX ) ) { throw new IllegalArgumentException ( "The prefix: " + prefix + " cannot be registered, it's reserved for special internal use." ) ; } if ( prefixToNamespaceURILookup . containsKey ( prefix ) ) { throw new IllegalArgumentException ( "The prefix: '" + prefix + "' was repeated. This is illegal." ) ; } if ( namespaceURIToPrefixLookup . containsKey ( nsURI ) ) { throw new IllegalArgumentException ( "The namespace URI: " + nsURI + " cannot be mapped to 2 different prefixes." ) ; } if ( prefix . equals ( DEFAULT_NAMESPACE_PREFIX ) ) { this . defaultNS = nsURI ; } else { prefixToNamespaceURILookup . put ( prefix , nsURI ) ; namespaceURIToPrefixLookup . put ( nsURI , prefix ) ; } }
this is used internally .
