I am building a web Crawler for Linked Data. I have differentiated between HTML and RDF/XML page by following code:
public static int checktype(URL url) throws IOException
{
String contentType = ((HttpURLConnection) url.openConnection()).getContentType();
System.out.println("Website is read");
int t=0;
if("text/html".equals(contentType)) {t=0;}
else if("application/rdf+xml".equals(contentType)) {t=1;}
System.out.println(contentType);
return t;
}
Now I want to parse a web page with RDF/XML data to extract all URIs from that page. I am able to find HTML parsers but not for Linked Data. Please help me further