在Android中如何解析HTML? [英] How can you parse HTML in android?

查看:238
本文介绍了在Android中如何解析HTML?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在为Android应用程序,以及应用程序的功能元素是从图书馆的目录的在线搜索返回结果。应用程序需要显示的搜索,这是通过自定义的HTML形式的方式,在一个方式符合应用程序的其余部分的结果。即,在搜索的结果需要被解析并显示的有用的元素。我只是想知道是否/如何可以在Android中实现?

I am making an application for android, and an element of the functionality of the application is to return results from an online search of a library's catalogue. The application needs to display the results of the search, which is carried out by way of a custom HTML form, in a manner in keeping with the rest of the application. Ie, the results of the search need to be parsed and the useful elements displayed. I was just wondering if/how this could be achieved in android?

推荐答案

您可以使用XmlPullParser解析XML。

You can use XmlPullParser for parsing XML.

有关如请参阅 http://developer.android.com/reference/org/xmlpull /v1/XmlPullParser.html

这篇关于在Android中如何解析HTML?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆