|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.xwiki.rendering.listener.chaining.AbstractChainingListener
public abstract class AbstractChainingListener
Default and basic implementation of a chaining listener that knows how to delegate event calls to the next listener in the chain.
| Field Summary |
|---|
| Fields inherited from interface org.xwiki.rendering.listener.Listener |
|---|
EMPTY_PARAMETERS |
| Constructor Summary | |
|---|---|
AbstractChainingListener()
|
|
| Method Summary | |
|---|---|
void |
beginDefinitionDescription()
Start of a definition list description. |
void |
beginDefinitionList(java.util.Map<java.lang.String,java.lang.String> parameters)
Start of a definition list. |
void |
beginDefinitionTerm()
Start of a definition list term. |
void |
beginDocument(MetaData metaData)
Start of the document. |
void |
beginFormat(Format format,
java.util.Map<java.lang.String,java.lang.String> parameters)
End of a text formatting block. |
void |
beginGroup(java.util.Map<java.lang.String,java.lang.String> parameters)
Start a group of elements. |
void |
beginHeader(HeaderLevel level,
java.lang.String id,
java.util.Map<java.lang.String,java.lang.String> parameters)
Start of a header. |
void |
beginLink(ResourceReference reference,
boolean isFreeStandingURI,
java.util.Map<java.lang.String,java.lang.String> parameters)
Start of a link. |
void |
beginList(ListType listType,
java.util.Map<java.lang.String,java.lang.String> parameters)
Start of a list. |
void |
beginListItem()
Start of a list item. |
void |
beginMacroMarker(java.lang.String name,
java.util.Map<java.lang.String,java.lang.String> parameters,
java.lang.String content,
boolean isInline)
Start of marker containing a macro definition. |
void |
beginMetaData(MetaData metadata)
Start of MetaData (eg saving source from where the content is coming from). |
void |
beginParagraph(java.util.Map<java.lang.String,java.lang.String> parameters)
Start of a paragraph. |
void |
beginQuotation(java.util.Map<java.lang.String,java.lang.String> parameters)
Start of a quotation. |
void |
beginQuotationLine()
Start of a quotation line. |
void |
beginSection(java.util.Map<java.lang.String,java.lang.String> parameters)
Start of a section. |
void |
beginTable(java.util.Map<java.lang.String,java.lang.String> parameters)
Start of a table. |
void |
beginTableCell(java.util.Map<java.lang.String,java.lang.String> parameters)
Start of a table cell. |
void |
beginTableHeadCell(java.util.Map<java.lang.String,java.lang.String> parameters)
Start of a table head cell. |
void |
beginTableRow(java.util.Map<java.lang.String,java.lang.String> parameters)
Start of a table row. |
void |
endDefinitionDescription()
End of a definition list description. |
void |
endDefinitionList(java.util.Map<java.lang.String,java.lang.String> parameters)
End of a definition list. |
void |
endDefinitionTerm()
End of a definition list term. |
void |
endDocument(MetaData metaData)
End of the document. |
void |
endFormat(Format format,
java.util.Map<java.lang.String,java.lang.String> parameters)
End of a text formatting block. |
void |
endGroup(java.util.Map<java.lang.String,java.lang.String> parameters)
End of the group. |
void |
endHeader(HeaderLevel level,
java.lang.String id,
java.util.Map<java.lang.String,java.lang.String> parameters)
End of a header. |
void |
endLink(ResourceReference reference,
boolean isFreeStandingURI,
java.util.Map<java.lang.String,java.lang.String> parameters)
End of a link. |
void |
endList(ListType listType,
java.util.Map<java.lang.String,java.lang.String> parameters)
End of a list. |
void |
endListItem()
End of a list item. |
void |
endMacroMarker(java.lang.String name,
java.util.Map<java.lang.String,java.lang.String> parameters,
java.lang.String content,
boolean isInline)
End of marker containing a macro definition. |
void |
endMetaData(MetaData metadata)
End of MetaData. |
void |
endParagraph(java.util.Map<java.lang.String,java.lang.String> parameters)
End of a paragraph. |
void |
endQuotation(java.util.Map<java.lang.String,java.lang.String> parameters)
End of a quotation. |
void |
endQuotationLine()
End of a quotation line. |
void |
endSection(java.util.Map<java.lang.String,java.lang.String> parameters)
End of a section. |
void |
endTable(java.util.Map<java.lang.String,java.lang.String> parameters)
End of a table. |
void |
endTableCell(java.util.Map<java.lang.String,java.lang.String> parameters)
End of a table cell. |
void |
endTableHeadCell(java.util.Map<java.lang.String,java.lang.String> parameters)
End of a table head cell. |
void |
endTableRow(java.util.Map<java.lang.String,java.lang.String> parameters)
End of a table row. |
ListenerChain |
getListenerChain()
|
void |
onEmptyLines(int count)
Represents an empty line between 2 standalone Blocks. |
void |
onHorizontalLine(java.util.Map<java.lang.String,java.lang.String> parameters)
Represents an horizontal line. |
void |
onId(java.lang.String name)
A reference/location in a page. |
void |
onImage(ResourceReference reference,
boolean isFreeStandingURI,
java.util.Map<java.lang.String,java.lang.String> parameters)
An image. |
void |
onMacro(java.lang.String id,
java.util.Map<java.lang.String,java.lang.String> parameters,
java.lang.String content,
boolean isInline)
A Macro. |
void |
onNewLine()
A new line or line break (it's up to the renderers to decide if it should be outputted as a new line or as a line break in the given syntax). |
void |
onRawText(java.lang.String text,
Syntax syntax)
Some text to inject directly into the listener output without parsing it. |
void |
onSpace()
A space. |
void |
onSpecialSymbol(char symbol)
A special symbol ("*", "<", ">", "=", quote, etc). |
void |
onVerbatim(java.lang.String protectedString,
boolean isInline,
java.util.Map<java.lang.String,java.lang.String> parameters)
A portion of text. |
void |
onWord(java.lang.String word)
A word. |
void |
setListenerChain(ListenerChain listenerChain)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public AbstractChainingListener()
| Method Detail |
|---|
public void setListenerChain(ListenerChain listenerChain)
listenerChain - see getListenerChain()public ListenerChain getListenerChain()
getListenerChain in interface ChainingListenerpublic void beginDefinitionDescription()
beginDefinitionDescription in interface ListenerListener.beginDefinitionDescription()public void beginDefinitionList(java.util.Map<java.lang.String,java.lang.String> parameters)
beginDefinitionList in interface Listenerparameters - a generic list of parameters for the list. Example: "style"/"background-color: blue"Listener.beginDefinitionList(java.util.Map)public void beginDefinitionTerm()
beginDefinitionTerm in interface ListenerListener.beginDefinitionTerm()public void beginDocument(MetaData metaData)
beginDocument in interface ListenermetaData - the meta data to associate to the following events, see MetaDataListener.beginDocument(org.xwiki.rendering.listener.MetaData)public void beginGroup(java.util.Map<java.lang.String,java.lang.String> parameters)
beginGroup in interface Listenerparameters - a generic list of parameters. Example: style="background-color: blue"Listener.beginGroup(Map)
public void beginFormat(Format format,
java.util.Map<java.lang.String,java.lang.String> parameters)
beginFormat in interface Listenerformat - the formatting type (bold, italic, etc)parameters - a generic list of parameters. Example: style="background-color: blue"Listener.beginFormat(Format, Map)
public void beginHeader(HeaderLevel level,
java.lang.String id,
java.util.Map<java.lang.String,java.lang.String> parameters)
beginHeader in interface Listenerlevel - the header level (1, 2, 3, etc)id - the header unique identifierparameters - a generic list of parameters. Example: style="background-color: blue"Listener.beginHeader(HeaderLevel, String, Map)
public void beginLink(ResourceReference reference,
boolean isFreeStandingURI,
java.util.Map<java.lang.String,java.lang.String> parameters)
beginLink in interface LinkListenerreference - the link referenceisFreeStandingURI - if true then the link is a free standing URI directly in the textparameters - a generic list of parameters. Example: style="background-color: blue"LinkListener.beginLink(org.xwiki.rendering.listener.reference.ResourceReference , boolean, Map)
public void beginList(ListType listType,
java.util.Map<java.lang.String,java.lang.String> parameters)
beginList in interface ListenerlistType - the type of list (bulleted, numbered, etc)parameters - a generic list of parameters for the list. Example: "style"/"background-color: blue"Listener.beginList(ListType, Map)public void beginListItem()
beginListItem in interface ListenerListener.beginListItem()
public void beginMacroMarker(java.lang.String name,
java.util.Map<java.lang.String,java.lang.String> parameters,
java.lang.String content,
boolean isInline)
beginMacroMarker in interface Listenername - the macro nameparameters - the macro parameterscontent - the macro contentisInline - if true the macro is located in a inline content (like paragraph, etc.)Listener.beginMacroMarker(String, Map, String, boolean)public void beginParagraph(java.util.Map<java.lang.String,java.lang.String> parameters)
beginParagraph in interface Listenerparameters - a generic list of parameters. Example: style="background-color: blue"Listener.beginParagraph(Map)public void beginQuotation(java.util.Map<java.lang.String,java.lang.String> parameters)
beginQuotation in interface Listenerparameters - a generic list of parameters for the quotation. Example: "style"/"background-color: blue"Listener.beginQuotation(Map)public void beginQuotationLine()
beginQuotationLine in interface ListenerListener.beginQuotationLine()public void beginSection(java.util.Map<java.lang.String,java.lang.String> parameters)
beginSection in interface Listenerparameters - a generic list of parameters. Example: style="background-color: blue"Listener.beginSection(Map)public void beginTable(java.util.Map<java.lang.String,java.lang.String> parameters)
beginTable in interface Listenerparameters - a generic list of parameters for the table.Listener.beginTable(Map)public void beginTableCell(java.util.Map<java.lang.String,java.lang.String> parameters)
beginTableCell in interface Listenerparameters - a generic list of parameters for the table cell.Listener.beginTableCell(Map)public void beginTableHeadCell(java.util.Map<java.lang.String,java.lang.String> parameters)
beginTableHeadCell in interface Listenerparameters - a generic list of parameters for the table head cell.Listener.beginTableHeadCell(Map)public void beginTableRow(java.util.Map<java.lang.String,java.lang.String> parameters)
beginTableRow in interface Listenerparameters - a generic list of parameters for the table row.Listener.beginTableRow(Map)public void beginMetaData(MetaData metadata)
beginMetaData in interface Listenermetadata - the metadataListener.beginMetaData(org.xwiki.rendering.listener.MetaData)public void endDefinitionDescription()
endDefinitionDescription in interface ListenerListener.endDefinitionDescription()public void endDefinitionList(java.util.Map<java.lang.String,java.lang.String> parameters)
endDefinitionList in interface Listenerparameters - a generic list of parameters for the list. Example: "style"/"background-color: blue"Listener.endDefinitionList(java.util.Map)public void endDefinitionTerm()
endDefinitionTerm in interface ListenerListener.endDefinitionTerm()public void endDocument(MetaData metaData)
endDocument in interface ListenermetaData - the meta data associated with the previous events, see MetaDataListener.endDocument(org.xwiki.rendering.listener.MetaData)public void endGroup(java.util.Map<java.lang.String,java.lang.String> parameters)
endGroup in interface Listenerparameters - a generic list of parameters. Example: style="background-color: blue"Listener.endGroup(Map)
public void endFormat(Format format,
java.util.Map<java.lang.String,java.lang.String> parameters)
endFormat in interface Listenerformat - the formatting type (bold, italic, etc)parameters - a generic list of parameters. Example: style="background-color: blue"Listener.endFormat(Format, Map)
public void endHeader(HeaderLevel level,
java.lang.String id,
java.util.Map<java.lang.String,java.lang.String> parameters)
endHeader in interface Listenerlevel - the header level (1, 2, 3, etc)id - the header unique identifierparameters - a generic list of parameters. Example: style="background-color: blue"Listener.endHeader(HeaderLevel, String, Map)
public void endLink(ResourceReference reference,
boolean isFreeStandingURI,
java.util.Map<java.lang.String,java.lang.String> parameters)
endLink in interface LinkListenerreference - the link referenceisFreeStandingURI - if true then the link is a free standing URI directly in the textparameters - a generic list of parameters. Example: style="background-color: blue"LinkListener.endLink(org.xwiki.rendering.listener.reference.ResourceReference , boolean, Map)
public void endList(ListType listType,
java.util.Map<java.lang.String,java.lang.String> parameters)
endList in interface ListenerlistType - the type of list (bulleted, numbered, etc)parameters - a generic list of parameters for the list. Example: "style"/"background-color: blue"Listener.endList(ListType, Map)public void endListItem()
endListItem in interface ListenerListener.endListItem()
public void endMacroMarker(java.lang.String name,
java.util.Map<java.lang.String,java.lang.String> parameters,
java.lang.String content,
boolean isInline)
endMacroMarker in interface Listenername - the macro nameparameters - the macro parameterscontent - the macro contentisInline - if true the macro is located in a inline content (like paragraph, etc.)Listener.endMacroMarker(String, Map, String, boolean)public void endParagraph(java.util.Map<java.lang.String,java.lang.String> parameters)
endParagraph in interface Listenerparameters - a generic list of parameters. Example: style="background-color: blue"Listener.endParagraph(Map)public void endQuotation(java.util.Map<java.lang.String,java.lang.String> parameters)
endQuotation in interface Listenerparameters - a generic list of parameters for the quotation. Example: "style"/"background-color: blue"Listener.endQuotation(Map)public void endQuotationLine()
endQuotationLine in interface ListenerListener.endQuotationLine()public void endSection(java.util.Map<java.lang.String,java.lang.String> parameters)
endSection in interface Listenerparameters - a generic list of parameters. Example: style="background-color: blue"Listener.endSection(Map)public void endTable(java.util.Map<java.lang.String,java.lang.String> parameters)
endTable in interface Listenerparameters - a generic list of parameters for the table.Listener.endTable(Map)public void endTableCell(java.util.Map<java.lang.String,java.lang.String> parameters)
endTableCell in interface Listenerparameters - a generic list of parameters for the table cell.Listener.endTableCell(Map)public void endTableHeadCell(java.util.Map<java.lang.String,java.lang.String> parameters)
endTableHeadCell in interface Listenerparameters - a generic list of parameters for the table head cell.Listener.endTableHeadCell(Map)public void endTableRow(java.util.Map<java.lang.String,java.lang.String> parameters)
endTableRow in interface Listenerparameters - a generic list of parameters for the table row.Listener.endTableRow(Map)public void endMetaData(MetaData metadata)
endMetaData in interface Listenermetadata - the metadataListener.endMetaData(org.xwiki.rendering.listener.MetaData)public void onEmptyLines(int count)
onEmptyLines in interface Listenercount - the number of empty lines between 2 standalone BlocksListener.onEmptyLines(int)public void onHorizontalLine(java.util.Map<java.lang.String,java.lang.String> parameters)
onHorizontalLine in interface Listenerparameters - a generic list of parameters. Example: style="background-color: blue"Listener.onHorizontalLine(Map)public void onId(java.lang.String name)
onId in interface Listenername - the location name.Listener.onId(String)
public void onImage(ResourceReference reference,
boolean isFreeStandingURI,
java.util.Map<java.lang.String,java.lang.String> parameters)
onImage in interface ImageListenerreference - the image referenceisFreeStandingURI - if true then the image is defined directly as a URI in the textparameters - a generic list of parameters. Example: style="background-color: blue"ImageListener.onImage(org.xwiki.rendering.listener.reference.ResourceReference , boolean, java.util.Map)
public void onMacro(java.lang.String id,
java.util.Map<java.lang.String,java.lang.String> parameters,
java.lang.String content,
boolean isInline)
onMacro in interface Listenerid - the macro id (eg "toc" for the TOC macro)parameters - the macro parameterscontent - the macro contentisInline - if true the macro is located in a inline content (like paragraph, etc.)Listener.onMacro(String, Map, String, boolean)public void onNewLine()
onNewLine in interface ListenerListener.onNewLine()public void onSpace()
onSpace in interface ListenerListener.onSpace()public void onSpecialSymbol(char symbol)
onSpecialSymbol in interface Listenersymbol - the symbol encounteredListener.onSpecialSymbol(char)
public void onVerbatim(java.lang.String protectedString,
boolean isInline,
java.util.Map<java.lang.String,java.lang.String> parameters)
onVerbatim in interface ListenerprotectedString - the string to protected from renderingisInline - if true the text content is located in a inline content (like paragraph, etc.)parameters - a generic list of parameters. Example: style="background-color: blue"Listener.onVerbatim(String, boolean, Map)public void onWord(java.lang.String word)
onWord in interface Listenerword - the word encounteredListener.onWord(String)
public void onRawText(java.lang.String text,
Syntax syntax)
onRawText in interface Listenertext - the text to injectsyntax - the syntax in which the text is written. This is useful so that listener implementations can decide
whether they can handle direct inject for that syntaxListener.onRawText(String, Syntax)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||