java.lang.Object | |
↳ | org.jsoup.nodes.Document.OutputSettings |
A Document's output settings control the form of the text() and html() methods.
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Get the document's current output charset, which is used to control which characters are escaped when
generating HTML (via the
html() methods), and which are kept intact. | |||||||||||
Update the document's output charset.
| |||||||||||
Update the document's output charset.
| |||||||||||
Get the document's current HTML escape mode:
base , which provides a limited set of named HTML
entities and escapes other characters as numbered entities for maximum compatibility; or extended ,
which uses the complete set of HTML named entities. | |||||||||||
Set the document's escape mode
| |||||||||||
Get the current tag indent amount, used when pretty printing.
| |||||||||||
Set the indent amount for pretty printing
| |||||||||||
Get if pretty printing is enabled.
| |||||||||||
Enable or disable pretty printing.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
|
Get the document's current output charset, which is used to control which characters are escaped when
generating HTML (via the html()
methods), and which are kept intact.
Where possible (when parsing from a URL or File), the document's output charset is automatically set to the input charset. Otherwise, it defaults to UTF-8.
Update the document's output charset.
charset | the new charset to use. |
---|
Update the document's output charset.
charset | the new charset (by name) to use. |
---|
Get the document's current HTML escape mode: base
, which provides a limited set of named HTML
entities and escapes other characters as numbered entities for maximum compatibility; or extended
,
which uses the complete set of HTML named entities.
The default escape mode is base
.
Set the document's escape mode
escapeMode | the new escape mode to use |
---|
Get the current tag indent amount, used when pretty printing.
Set the indent amount for pretty printing
indentAmount | number of spaces to use for indenting each level. Must be >= 0. |
---|
Get if pretty printing is enabled. Default is true. If disabled, the HTML output methods will not re-format the output, and the output will generally look like the input.
Enable or disable pretty printing.
pretty | new pretty print setting |
---|