public class ParseSettings
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static ParseSettings |
htmlDefault
HTML default settings: both tag and attribute names are lower-cased during parsing.
|
private boolean |
preserveAttributeCase |
static ParseSettings |
preserveCase
Preserve both tag and attribute case.
|
private boolean |
preserveTagCase |
Constructor and Description |
---|
ParseSettings(boolean tag,
boolean attribute)
Define parse settings.
|
ParseSettings(ParseSettings copy) |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
normalizeAttribute(java.lang.String name)
Normalizes an attribute according to the case preservation setting.
|
(package private) Attributes |
normalizeAttributes(Attributes attributes) |
java.lang.String |
normalizeTag(java.lang.String name)
Normalizes a tag name according to the case preservation setting.
|
(package private) static java.lang.String |
normalName(java.lang.String name)
Returns the normal name that a Tag will have (trimmed and lower-cased)
|
boolean |
preserveAttributeCase()
Returns true if preserving attribute case.
|
boolean |
preserveTagCase()
Returns true if preserving tag name case.
|
public static final ParseSettings htmlDefault
public static final ParseSettings preserveCase
private final boolean preserveTagCase
private final boolean preserveAttributeCase
public ParseSettings(boolean tag, boolean attribute)
tag
- preserve tag case?attribute
- preserve attribute name case?ParseSettings(ParseSettings copy)
public boolean preserveTagCase()
public boolean preserveAttributeCase()
public java.lang.String normalizeTag(java.lang.String name)
public java.lang.String normalizeAttribute(java.lang.String name)
@Nullable Attributes normalizeAttributes(@Nullable Attributes attributes)
static java.lang.String normalName(java.lang.String name)