jsoup 1.11.2 发布,Java 的 HTML 解析器

栏目: 软件资讯 · 发布时间: 8年前

内容简介:jsoup 是一款 Java 的HTML 解析器,可直接解析某个URL地址、HTML文本内容。它提供了一套非常省力的API,可通过DOM,CSS以及类似于JQuery的操作方法来取出和操作数据。 jsoup的主要功能如下: 从一个URL,文件或字...

jsoup 是一款 Java 的HTML 解析器,可直接解析某个URL地址、HTML文本内容。它提供了一套非常省力的API,可通过DOM,CSS以及类似于JQuery的操作方法来取出和操作数据。

jsoup的主要功能如下:

  1. 从一个URL,文件或字符串中解析HTML;

  2. 使用DOM或CSS选择器来查找、取出数据;

  3. 可操作HTML元素、属性、文本;

jsoup是基于MIT协议发布的,可放心使用于商业项目。

此次更新内容:

改进

  • Added a new pseudo selector :matchText, which allows text nodes to match as if they were elements. This enables finding text that is only marked by a brtag, for example.

  • Change: marked Connection.validateTLSCertificates() as deprecated.

  • Normalize invisible characters (like soft-hyphens) in Element.text().

  • Added Element.wholeText(), to easily get the un-normalized text value of an element and its children.

bug 修复

  • Bugfix: in a deep DOM stack, a StackOverFlow exception could occur when generating implied end tags.

  • Bugfix: when parsing attribute values that happened to cross a buffer boundary, a character was dropped.

  • Bugfix: fixed an issue that prevented using infinite timeouts in Jsoup.Connection.

  • Bugfix: whitespace preserving tags were not honoured when nested deeper than two levels deep.

  • Bugfix: an unterminated comment token at the end of the HTML input would cause an out of bounds exception.

  • Bugfix: an NPE in the Cleaner which would occur if an <a href> attribute value was missing.

  • Bugfix: when serializing the same document in a multiple threads, on Android, with a character set that is not ascii or UTF-8, an encoding exception could occur.

  • Bugfix: removing a form value from the DOM would not remove it from FormData.

  • Bugfix: in the W3CDom transformer, siblings were incorrectly inheriting namespaces defined on previous siblings.

下载地址:


【声明】文章转载自:开源中国社区 [http://www.oschina.net]


以上就是本文的全部内容,希望本文的内容对大家的学习或者工作能带来一定的帮助,也希望大家多多支持 码农网

查看所有标签

猜你喜欢:

本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们

架构真经

架构真经

马丁L. 阿伯特(Martin L. Abbott)、迈克尔T.费舍尔(Michael T. Fisher) / 机械工业出版社 / 2017-4 / 79

前言 感谢你对本书第2版感兴趣!作为一本入门、进修和轻量级的参考手册,本书旨在帮助工程师、架构师和管理者研发及维护可扩展的互联网产品。本书给出了一系列规则,每个规则围绕着不同的主题展开讨论。大部分的规则聚焦在技术上,少数规则涉及一些关键的思维或流程问题,每个规则对构建可扩展的产品都是至关重要的。这些规则在深度和焦点上都有所不同。有些规则是高级的,例如定义一个可以应用于几乎任何可扩展性问题的模......一起来看看 《架构真经》 这本书的介绍吧!

HTML 压缩/解压工具
HTML 压缩/解压工具

在线压缩/解压 HTML 代码

CSS 压缩/解压工具
CSS 压缩/解压工具

在线压缩/解压 CSS 代码

URL 编码/解码
URL 编码/解码

URL 编码/解码