Jsoup1.7.3 released, powerful HTML parser

Source: Internet
Author: User
Jsoup has just released version 1.7.3, which improves the performance of form processing, more reliable character set detection, CSS selector and resolution, and memory optimization, and fixes some bugs. Jsoup is a Java HTML parser that can directly parse a URL address and HTML text content. It provides a set of very labor-saving APIs, including DOM, CSS, and JQuery-like operations. "/> jsoup has just released version 1.7.3, it improves the performance of form processing, more reliable character set detection, CSS selector and parsing, and memory optimization, and fixes some bugs.

Jsoup is a Java HTML parser that can directly parse a URL address and HTML text content. It provides a set of very labor-saving APIs that can be used to retrieve and manipulate data through DOM, CSS, and operations similar to JQuery.

The main functions of jsoup are as follows:

Parse HTML from a URL, file, or string;
Use the DOM or CSS selector to find and retrieve data;
HTML elements, attributes, and text can be operated;
Jsoup is released based on the MIT protocol and can be safely used in commercial projects.

The detailed improvements are as follows:

Improvements:
-Added the element type FormElement, to facilitate simple form submissions. Find forms in a doc using Elements. forms (), then prepare it for submission with FormElement. submit ().
-Improved the reliability of HTTP character-set recognition from response headers, fig for when servers return out-of-spec responses.
-Added Document. location () to retrieve the document's location URL. Handy if the request was redirected from the original URL.
-Large decrease in the amount of temporary objects created during parsing, leading to less GC load (helpful participant ularly on Android), and faster parsing.
-Improved the time to match elements with common CSS selectors ~ 27%.
Bug Fixes:
-Fixed support for self-closing script tags.
-Fixed a crash when reading an unterminated CDATA section.
-Fixed an issue where elements added via the adoption agency algorithm did not preserve their attributes.
-Fixed an issue when cloning a document with extremely nested elements that cocould cause a stack-overflow.
-Fixed an issue when connecting or redirecting to a URL that contains a space.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.