1

So I am using rome and accessing a feed with the following url

URL url = new URL("feed://rss.cnn.com/rss/cnn_topstories.rss");
reader = new XmlReader(url);

(unrelated code edited out)

however, I get the following exception:

Exception in thread "main" java.net.MalformedURLException: unknown protocol: feed
at java.net.URL.<init>(URL.java:574)
at java.net.URL.<init>(URL.java:464)
at java.net.URL.<init>(URL.java:413)
at Browser.getFeed(Browser.java:84)
at Browser.doBrowser(Browser.java:49)
at Browser.main(Browser.java:38)

How do I parse this feed?

Alex
  • 690
  • 1
  • 9
  • 29

1 Answers1

3

Replace "feed://" with "http://" and you'll be fine.

iluxa
  • 6,941
  • 18
  • 36