code: private Document loadXML(URL url, boolean useNamespace) {
  		InputStream stream = null;
  		try {
  			stream = url.openConnection().getInputStream();
  			InputSource source = new InputSource(stream);
  			return useNamespace ? loadXMLNS(source) : loadXML(source);
  		} catch (Exception e) {
  			throw new DomException(e);
  		} finally {
  			close(stream);
  		}
  	}
docs: Helper method to load XML document from URL.
  
  @param url source URL,
  @param useNamespace flag to control name space awareness.
  @return newly created XML document.