// code copied from HttpClientUrlConnect.createMethod - without normalizing // both encoded and unencoded urls will be preserved public String normalizeUrl(String urlString, ArchivalUnit au) throws PluginException { String u_str = urlString; /* if the urlString is not "readable" ascii (0x1F < x < 0x7f), then * normalize/encode the string */ if (!isReadableAscii(urlString)) { if (log.isDebug2()) log.debug2("in:" + u_str); u_str = UrlUtil.encodeUri(urlString, Constants.ENCODING_UTF_8); if (log.isDebug2()) log.debug2("out:" + u_str); } return u_str; }