MCPcopy Create free account
hub / github.com/apache/nutch / reverseUrl

Method reverseUrl

src/java/org/apache/nutch/util/TableUtil.java:41–44  ·  view source on GitHub ↗

Reverses a url's domain. This form is better for storing in hbase. Because scans within the same domain are faster. E.g. "http://bar.foo.com:8983/to/index.html?a=b" becomes "com.foo.bar:8983:http/to/index.html?a=b". @param urlString url to be reversed @return Reversed url @throws Malfo

(String urlString)

Source from the content-addressed store, hash-verified

39 * @throws MalformedURLException
40 */
41 public static String reverseUrl(String urlString)
42 throws MalformedURLException {
43 return reverseUrl(new URL(urlString));
44 }
45
46 /**
47 * Reverses a url's domain. This form is better for storing in hbase. Because

Callers 15

setUpMethod · 0.95
testGenerateHighestMethod · 0.95
testGenerateHostLimitMethod · 0.95
testFilterMethod · 0.95
assertReverseMethod · 0.95
endElementMethod · 0.95
outputMethod · 0.95
readMethod · 0.95
processSitemapParseMethod · 0.95
reverseKeyMethod · 0.95

Calls 6

reverseAppendSplitsMethod · 0.95
getProtocolMethod · 0.80
getPortMethod · 0.80
getHostMethod · 0.45
appendMethod · 0.45
toStringMethod · 0.45

Tested by 7

setUpMethod · 0.76
testGenerateHighestMethod · 0.76
testGenerateHostLimitMethod · 0.76
testFilterMethod · 0.76
assertReverseMethod · 0.76