Results 1 to 17 of 17
Thread: RSS Reader
- 04-19-2010, 07:22 PM #1
Member
- Join Date
- Apr 2010
- Posts
- 8
- Rep Power
- 0
RSS Reader
Hello. I briefly searched the forums and could not find a thread on RSS. In short, I am fairly new to Java and I am trying to create my own RSS reader. I have tried a search on the web for any samples to use as a guide. However, I keep running into the same problems when I try to use ROME or the Sun RSS Utilities-- "Package com.sun.syndication.feed.synd.SyndFeed does not exist." Ultimately, I just want to be able to point the program to some RSS feeds, retrieve the information, and output it to a console. Has anyone some experience with this? If so, i just need some clarification on what I am doing wrong.
--Thank you!
- 04-20-2010, 03:57 AM #2
- Join Date
- Jul 2007
- Location
- Colombo, Sri Lanka
- Posts
- 11,374
- Blog Entries
- 1
- Rep Power
- 18
I think if you really want to build your own RSS reader, then MUST have a clear idea on how RSS works, I mean how it's organized internally. Do you aware of that?
- 04-20-2010, 04:00 AM #3
- Join Date
- Jul 2007
- Location
- Colombo, Sri Lanka
- Posts
- 11,374
- Blog Entries
- 1
- Rep Power
- 18
Rome is the best you can find for that actually. If you have misses some additional JAR packages, then search there site. I'm sure you can find those.
- 04-20-2010, 07:45 AM #4
Member
- Join Date
- Apr 2010
- Posts
- 8
- Rep Power
- 0
Thanks Eranga. As far as I know: RSS is used to publish any work that is updated frequently. Like news, blogs, etc. The data is shared using any of the common RSS standards. I understand that the data is transmitted via an XML file formatted to any of the standards. At this point I do not want to publish any feeds. I just want to create a program that would read the feeds. But I think you have a good point about learning the internal workings of RSS. I will try again with the ROME tutorial and post my progress.
- 04-20-2010, 11:49 AM #5
- Join Date
- Jul 2007
- Location
- Colombo, Sri Lanka
- Posts
- 11,374
- Blog Entries
- 1
- Rep Power
- 18
Since data passing through XML, you can think about a XML parser as well. But in that case we have one difficulty that how data should be capture. Say I've a web site and I keep data in specific data in a database, but others may not in the same way. So in that case we must think a way, a common way, to access resources. Actually that's what RSS readers does, using different logic.
- 04-21-2010, 09:29 AM #6
Member
- Join Date
- Apr 2010
- Posts
- 8
- Rep Power
- 0
Okay. So I have found some examples online. I am using the examples so that I can understand how it all works. However, I am trying to compile the code and I keep getting the following error:
:confused:
"import com.sun.syndication.feed.synd.*;
import com.sun.syndication.io.SyndFeedOutput;"
If I post the code on this thread, can you help me identify what could be the problem? The code is 32 lines long with indents, blank lines, and comments. I do know that you are busy and I appreciate all your help.:)
- 04-21-2010, 05:13 PM #7
- Join Date
- Jul 2007
- Location
- Colombo, Sri Lanka
- Posts
- 11,374
- Blog Entries
- 1
- Rep Power
- 18
That is not a standard package comes with JDK. So what you've to do is that find this JAR package and import it into your project. Did you have that package with you?com.sun.syndication.feed.synd.*
- 04-21-2010, 05:15 PM #8
- Join Date
- Jul 2007
- Location
- Colombo, Sri Lanka
- Posts
- 11,374
- Blog Entries
- 1
- Rep Power
- 18
At the moment no need to send your code here lol. If it's really required then you can post a relevant code segment. This is nothing wrong with the coding you've done, this is about missing some required resources in your code. :)
- 04-22-2010, 12:54 AM #9
Member
- Join Date
- Apr 2010
- Posts
- 8
- Rep Power
- 0
HAHA! I figured it out! :D I realized that I had all the correct packages but I kept loading the jdom-1.1.1.zip file instead of the jdom-1.1.1.jar file inside the *.zip file. Thank you Eranga!
I will continue with my project and let you know how it goes! Thanks again!:D
- 04-22-2010, 04:10 AM #10
- Join Date
- Jul 2007
- Location
- Colombo, Sri Lanka
- Posts
- 11,374
- Blog Entries
- 1
- Rep Power
- 18
You are welcome.
And of course it's much better added them in the class path, so you can use them in any project if you want. Are you using an IDE for coding? Most the IDEs not added them to the class path, instead added only in specified project.
- 04-23-2010, 04:53 PM #11
Member
- Join Date
- Apr 2010
- Posts
- 8
- Rep Power
- 0
Yes. I am using Eclipse IDE. But I do not know how to add the packages to the class path.
- 04-23-2010, 06:17 PM #12
- Join Date
- Jul 2007
- Location
- Colombo, Sri Lanka
- Posts
- 11,374
- Blog Entries
- 1
- Rep Power
- 18
In Eclipse there should be a way to added additional packages into your project. Did you know how to do that? I cannot exactly say that how to do it, because I'm not an Eclipse user.
- 04-23-2010, 06:17 PM #13
- Join Date
- Jul 2007
- Location
- Colombo, Sri Lanka
- Posts
- 11,374
- Blog Entries
- 1
- Rep Power
- 18
Play around with the IDE, you'll find the way to do that.
- 04-24-2010, 02:12 AM #14
Member
- Join Date
- Apr 2010
- Posts
- 8
- Rep Power
- 0
I found out how. In the project properties dialog I was able to add external *.jar files. It has worked since then. Thanks again!:)
- 04-24-2010, 02:08 PM #15
- Join Date
- Jul 2007
- Location
- Colombo, Sri Lanka
- Posts
- 11,374
- Blog Entries
- 1
- Rep Power
- 18
You are welcome. And if you satisfied with the answers I gave to you, it's time to mark your thread solved.
And also don't forget to give your updates on your project. ;)
- 04-24-2010, 06:13 PM #16
Member
- Join Date
- Apr 2010
- Posts
- 8
- Rep Power
- 0
Indeed. I believe this has been solved. Again thank you for all your help:)
- 04-25-2010, 01:41 PM #17
- Join Date
- Jul 2007
- Location
- Colombo, Sri Lanka
- Posts
- 11,374
- Blog Entries
- 1
- Rep Power
- 18
Similar Threads
-
Buffered Reader
By ilovepolluting in forum New To JavaReplies: 2Last Post: 02-04-2010, 09:16 AM -
help with input reader
By masterhoulahan in forum New To JavaReplies: 2Last Post: 03-25-2009, 05:12 AM -
Maze reader
By bix in forum New To JavaReplies: 1Last Post: 11-20-2008, 06:06 PM -
A simple DOM reader
By Java Tip in forum Java TipReplies: 0Last Post: 01-03-2008, 09:24 AM -
help with file reader
By jason27131 in forum New To JavaReplies: 1Last Post: 08-01-2007, 03:03 AM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks