| Modifier and Type | Class and Description |
|---|---|
| public static class | EmptyElementHandler.
HTML specific empty element handler. |
| public static class | EmptyElementHandler.
Handler that uses a Set of Strings. |
| Modifier and Type | Method and Description |
|---|---|
| public boolean | Returns: True if the empty element can be self-closing. False if a separate end tag should be written.The element's namespace prefix, null if not set prefix, String The element's local name localName, String The elements's namespace URI, null if not set nsURI, boolean The allow empty setting specified by the caller. allowEmpty)
|
| allowEmptyElement | back to summary |
|---|---|
public boolean allowEmptyElement(String prefix, String localName, String nsURI, boolean allowEmpty)
| |
SetEmptyElementHandler and configures
the HTML elements that must be self-closing according to the W3C:
http://www.w3.org/TR/html4/index/elements.html
Note that element name comparison is case-insensitive as required by HTML specification.
| Modifier and Type | Field and Description |
|---|---|
| private static final EmptyElementHandler. |
| Access | Constructor and Description |
|---|---|
| protected |
| Modifier and Type | Method and Description |
|---|---|
| public static EmptyElementHandler. |
| sInstance | back to summary |
|---|---|
| private static final EmptyElementHandler. | |
| HtmlEmptyElementHandler | back to summary |
|---|---|
| protected HtmlEmptyElementHandler() | |
| getInstance | back to summary |
|---|---|
| public static EmptyElementHandler. | |
Users of this class are encouraged to use a TreeSet with the String#CASE_INSENSITIVE_ORDER
comparator if case-insensitive comparison is needed (like when dealing with HTML tags).
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public boolean | allowEmptyElement(String
The element's namespace prefix, null if not set prefix, String The element's local name localName, String The elements's namespace URI, null if not set nsURI, boolean The allow empty setting specified by the caller. allowEmpty)Implements com.
|
| mEmptyElements | back to summary |
|---|---|
| protected final Set<String> mEmptyElements | |
| SetEmptyElementHandler | back to summary |
|---|---|
| public SetEmptyElementHandler(Set<String> emptyElements) | |
| allowEmptyElement | back to summary |
|---|---|
| public boolean allowEmptyElement(String prefix, String localName, String nsURI, boolean allowEmpty) Implements com.
| |