Java Code Examples for org.jsoup.parser.Parser#parse()

The following examples show how to use org.jsoup.parser.Parser#parse() . These examples are extracted from open source projects. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
/**
 * 将 html 字符串读取为 jsoup Document
 *
 * @param html String
 * @return Document
 */
public static Document readDocument(String html) {
	return Parser.parse(html, "");
}
 
Example 2
Source Project: astor   File: Jsoup.java    License: GNU General Public License v2.0 votes vote down vote up
/**
 Parse HTML into a Document. The parser will make a sensible, balanced document tree out of any HTML.

 @param html    HTML to parse
 @param baseUri The URL where the HTML was retrieved from. Used to resolve relative URLs to absolute URLs, that occur
 before the HTML declares a {@code <base href>} tag.
 @return sane HTML
 */
public static Document parse(String html, String baseUri) {
    return Parser.parse(html, baseUri);
}
 
Example 3
Source Project: astor   File: Jsoup.java    License: GNU General Public License v2.0 votes vote down vote up
/**
 Parse HTML into a Document. As no base URI is specified, absolute URL detection relies on the HTML including a
 {@code <base href>} tag.

 @param html HTML to parse
 @return sane HTML

 @see #parse(String, String)
 */
public static Document parse(String html) {
    return Parser.parse(html, "");
}
 
Example 4
Source Project: astor   File: Jsoup.java    License: GNU General Public License v2.0 votes vote down vote up
/**
 Parse HTML into a Document. The parser will make a sensible, balanced document tree out of any HTML.

 @param html    HTML to parse
 @param baseUri The URL where the HTML was retrieved from. Used to resolve relative URLs to absolute URLs, that occur
 before the HTML declares a {@code <base href>} tag.
 @return sane HTML
 */
public static Document parse(String html, String baseUri) {
    return Parser.parse(html, baseUri);
}
 
Example 5
Source Project: astor   File: Jsoup.java    License: GNU General Public License v2.0 votes vote down vote up
/**
 Parse HTML into a Document. As no base URI is specified, absolute URL detection relies on the HTML including a
 {@code <base href>} tag.

 @param html HTML to parse
 @return sane HTML

 @see #parse(String, String)
 */
public static Document parse(String html) {
    return Parser.parse(html, "");
}
 
Example 6
Source Project: astor   File: Jsoup.java    License: GNU General Public License v2.0 votes vote down vote up
/**
 Parse HTML into a Document. The parser will make a sensible, balanced document tree out of any HTML.

 @param html    HTML to parse
 @param baseUri The URL where the HTML was retrieved from. Used to resolve relative URLs to absolute URLs, that occur
 before the HTML declares a {@code <base href>} tag.
 @return sane HTML
 */
public static Document parse(String html, String baseUri) {
    return Parser.parse(html, baseUri);
}
 
Example 7
Source Project: astor   File: Jsoup.java    License: GNU General Public License v2.0 votes vote down vote up
/**
 Parse HTML into a Document. As no base URI is specified, absolute URL detection relies on the HTML including a
 {@code <base href>} tag.

 @param html HTML to parse
 @return sane HTML

 @see #parse(String, String)
 */
public static Document parse(String html) {
    return Parser.parse(html, "");
}
 
Example 8
Source Project: jsoup-learning   File: Jsoup.java    License: MIT License votes vote down vote up
/**
 Parse HTML into a Document. The parser will make a sensible, balanced document tree out of any HTML.

 @param html    HTML to parse
 @param baseUri The URL where the HTML was retrieved from. Used to resolve relative URLs to absolute URLs, that occur
 before the HTML declares a {@code <base href>} tag.
 @return sane HTML
 */
public static Document parse(String html, String baseUri) {
    return Parser.parse(html, baseUri);
}
 
Example 9
Source Project: jsoup-learning   File: Jsoup.java    License: MIT License votes vote down vote up
/**
 Parse HTML into a Document. As no base URI is specified, absolute URL detection relies on the HTML including a
 {@code <base href>} tag.

 @param html HTML to parse
 @return sane HTML

 @see #parse(String, String)
 */
public static Document parse(String html) {
    return Parser.parse(html, "");
}