I have this following XML and i need to parse it in an Android app. I already constructed a parser that works pretty well but for XML formats like this http://dl.dropbox.com/u/6751304/Nicosia.xml
Now i have to parse something like this http://www.cytanet.com.cy/Services/connectivity/basic/wireless/GoogleMaps/wifimarkers.xml
the previous parser i used does not display any results. i get a blank loooooong list so i guess it reads the marker label. I also know that the xml is parsed because i can Log.e it in the logcat, but the elements are not read
Can someone recognize the formatting of the second XML file and point to a tutorial/info on how to parse it?
(I can post the current code if needed)
I usually use a SAX Parser, but you are looking for different attributes & different tags.
Looks like this article should get you started (Covers Sax parsing)
http://xjaphx.wordpress.com/2011/10/09/android-xml-adventure-parsing-data-with-saxparser/
Basically in your StartElement you would grab the attributes
atts.getValue(MyAttribute.ID)
One reason for having both is something like this :
And to add to this.. One reason for having both would be to parse something like this :
Where you want to give an element an attribute which describes it.