Parsing XML from website to an Android device

后端 未结 5 1380
猫巷女王i
猫巷女王i 2021-02-10 15:56

I am starting an Android application that will parse XML from the web. I\'ve created a few Android apps but they\'ve never involved parsing XML and I was wondering if anyone had

5条回答
  •  醉话见心
    2021-02-10 16:24

    I would use the DOM parser, it is not as efficient as SAX, if the XML file is not too large, as it is easier in that case.

    I have made just one android App, that involved XML parsing. XML received from a SOAP web service. I used XmlPullParser. The implementation from Xml.newPullParser() had a bug where calls to nextText() did not always advance to the END_TAG as the documentation promised. There is a work around for this.

提交回复
热议问题