public class IdentityHtmlMapper extends java.lang.Object implements HtmlMapper
| Modifier and Type | Field and Description |
|---|---|
static HtmlMapper |
INSTANCE |
| Constructor and Description |
|---|
IdentityHtmlMapper() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
isDiscardElement(java.lang.String name)
Checks whether all content within the given HTML element should be
discarded instead of including it in the parse output.
|
java.lang.String |
mapSafeAttribute(java.lang.String elementName,
java.lang.String attributeName)
Maps "safe" HTML attribute names to semantic XHTML equivalents.
|
java.lang.String |
mapSafeElement(java.lang.String name)
Maps "safe" HTML element names to semantic XHTML equivalents.
|
public static final HtmlMapper INSTANCE
public boolean isDiscardElement(java.lang.String name)
HtmlMapperisDiscardElement in interface HtmlMappername - HTML element name (upper case)true if content inside the named element
should be ignored, false otherwisepublic java.lang.String mapSafeAttribute(java.lang.String elementName,
java.lang.String attributeName)
HtmlMappernull and the attribute
will be ignored. This method assumes that the element name
is valid and normalised.mapSafeAttribute in interface HtmlMapperelementName - HTML element name (lower case)attributeName - HTML attribute name (lower case)null if the element is unsafepublic java.lang.String mapSafeElement(java.lang.String name)
HtmlMappernull and the element
will be ignored but the content inside it is still processed. See
the HtmlMapper.isDiscardElement(String) method for a way to discard
the entire contents of an element.mapSafeElement in interface HtmlMappername - HTML element name (upper case)null if the element is unsafeCopyright © 2010 - 2023 Adobe. All Rights Reserved