How to read multiple rss xml files in j2me
Question
I already developed Rss feed reader application in j2me java using kxmlParser,
for one rss xml file(if i read one xml ,my code should be executed and list screen should be displayed) Now i want to apply the same code to 5 rss xml files(i.e i need to read one by one xml files) How can it possible in j2me?any help?
Solution
If you can parse one xml at a time:
- Create a Vector to control the xml queue
- Have a Thread consume the xml objects from the queue reusing the kxmlParser
If you need to parse all xmls at the same time
- Create a thread for each xml and a kxmlParser instance for each xml
First approach is slower but will run with less memory and is simpler to implement.
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow