org.xwiki.xml.internal.html.filter
Class ListItemFilter

java.lang.Object
  extended by org.xwiki.xml.html.filter.AbstractHTMLFilter
      extended by org.xwiki.xml.internal.html.filter.ListItemFilter
All Implemented Interfaces:
HTMLFilter, HTMLConstants

@Component
@Named(value="listitem")
@Singleton
public class ListItemFilter
extends AbstractHTMLFilter

If <li> elements have no <ul> or <ol> parent then add a <ul> parent to make it valid.

Since:
3.2RC1

Field Summary
 
Fields inherited from interface org.xwiki.xml.html.HTMLConstants
ATTRIBUTE_ALIGN, ATTRIBUTE_ALT, ATTRIBUTE_CLASS, ATTRIBUTE_FONTCOLOR, ATTRIBUTE_FONTFACE, ATTRIBUTE_FONTSIZE, ATTRIBUTE_HREF, ATTRIBUTE_NAME, ATTRIBUTE_ROWSPAN, ATTRIBUTE_SRC, ATTRIBUTE_STYLE, TAG_A, TAG_ABBR, TAG_ACRONYM, TAG_ADDRESS, TAG_B, TAG_BLOCKQUOTE, TAG_BODY, TAG_BR, TAG_CENTER, TAG_CITE, TAG_CODE, TAG_DEL, TAG_DFN, TAG_DIV, TAG_DL, TAG_EM, TAG_FIELDSET, TAG_FONT, TAG_FORM, TAG_H1, TAG_H2, TAG_H3, TAG_H4, TAG_H5, TAG_H6, TAG_HEAD, TAG_HR, TAG_HTML, TAG_I, TAG_IMG, TAG_INS, TAG_KBD, TAG_LI, TAG_NOSCRIPT, TAG_OL, TAG_P, TAG_PRE, TAG_Q, TAG_S, TAG_SAMP, TAG_SCRIPT, TAG_SPAN, TAG_STRIKE, TAG_STRONG, TAG_STYLE, TAG_TABLE, TAG_TD, TAG_TH, TAG_TR, TAG_U, TAG_UL, TAG_VAR, WHITE_SPACE_CHARS
 
Constructor Summary
ListItemFilter()
           
 
Method Summary
 void filter(Document document, Map<String,String> cleaningParameters)
          Performs cleaning of the html code stored in Document.
 
Methods inherited from class org.xwiki.xml.html.filter.AbstractHTMLFilter
filterChildren, filterDescendants, filterDescendants, hasAttribute, moveChildren, replaceWithChildren
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ListItemFilter

public ListItemFilter()
Method Detail

filter

public void filter(Document document,
                   Map<String,String> cleaningParameters)
Description copied from interface: HTMLFilter
Performs cleaning of the html code stored in Document.

Parameters:
document - The Document with html code
cleaningParameters - additional cleaning parameters for the filter.