ORG.oclc.kilroy.util
Class KilroyURL
java.lang.Object
|
+--ORG.oclc.kilroy.util.KilroyURL
- public class KilroyURL
- extends Object
A class for the harvester and related classes to use to pass around
URLs that are parsed and "normalized" to the standards of the harvester
(fully-qualified, lowercase host name, no relative #refs, spaces -> +).
This does not include normalizing IP addresses to domain names or vice
versa for the host component!
Using this class allieviates the need to parse URLs in multiple places
in the Kilroy harvester code.
NOTE: At the time this code was written, java.net.URL was not a
reliable alternative. It did not always parse URLs correctly
or recognize some protocols.
KilroyURL
public KilroyURL(URL u)
KilroyURL
public KilroyURL(String u)
KilroyURL
public KilroyURL(URL u,
String s)
getUrl
public String getUrl()
getProtocol
public String getProtocol()
getHost
public String getHost()
getPort
public int getPort()
getFile
public String getFile()
getExt
public String getExt()
toString
public String toString()
- Overrides:
- toString in class Object
meetsHarvestCriteria
public boolean meetsHarvestCriteria()
main
public static void main(String[] args)