|
Jive Forums API (5.5.20.2-oracle) Developer Javadocs | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.jivesoftware.forum.renderer.AbstractRenderFilter
public abstract class AbstractRenderFilter
An abstract implementation of the RenderFilter interface this class provides subclasses with built in support for documentation and splits apart the execute method into seperate methods depending on the render target specified in the render context.
Constructor Summary | |
---|---|
AbstractRenderFilter()
|
Method Summary | |
---|---|
java.lang.String |
execute(java.lang.String string,
RenderContext renderContext)
Applies the filter to the passed in string and returns the filtered string. |
protected abstract java.lang.String |
executeHtmlTarget(java.lang.String string,
RenderContext renderContext)
This method is called to execute the filter when the render target specified in the context is RenderTarget.TARGET_HTML . |
protected abstract java.lang.String |
executeNoMarkupTarget(java.lang.String string,
RenderContext renderContext)
This method is called to execute the filter when the render target specified in the context is RenderTarget.TARGET_NO_MARKUP . |
protected abstract java.lang.String |
executePlainEmailTarget(java.lang.String string,
RenderContext renderContext)
This method is called to execute the filter when the render target specified in the context is RenderTarget.TARGET_PLAIN_EMAIL . |
protected abstract java.lang.String |
executePlainTextTarget(java.lang.String string,
RenderContext renderContext)
This method is called to execute the filter when the render target specified in the context is RenderTarget.TARGET_PLAIN_TEXT . |
protected abstract java.lang.String |
executeWysiwygEditorTarget(java.lang.String string,
RenderContext renderContext)
This method is called to execute the filter when the render target specified in the context is RenderTarget.TARGET_WYSIWYG_EDITOR . |
protected abstract java.lang.String[] |
getDefaultHelp()
Returns a String[section,title,body] for the default help for the filter. |
protected abstract java.util.Map |
getDocumentationMap()
Returns a documentation Map keyed by languageCode -> String[section,title,body]. |
abstract java.lang.String |
getName()
Returns the unique name of the filter. |
java.lang.String[] |
getUserDocumentation(java.lang.String language)
Returns a string array of [section,title, body] of xml formatted documentation that is targetted for end user usage. |
boolean |
isEnabled()
Returns true if the filter is enabled, false otherwise. |
protected abstract boolean |
isEnabledByDefault()
Returns true if the filter should be enabled by default, false otherwise. |
void |
setEnabled(boolean enabled)
Sets whether the filter is enabled or disabled. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public AbstractRenderFilter()
Method Detail |
---|
public abstract java.lang.String getName()
RenderFilter
getName
in interface RenderFilter
public boolean isEnabled()
RenderFilter
isEnabled
in interface RenderFilter
public void setEnabled(boolean enabled)
RenderFilter
setEnabled
in interface RenderFilter
enabled
- true if the filter should be enabled, false otherwise.protected abstract boolean isEnabledByDefault()
public java.lang.String execute(java.lang.String string, RenderContext renderContext)
RenderFilter
RenderStrategy
denotes that links should not be filtered and
the current filter does nothing but change text to links, then the filter should
just return the input string.RenderTarget
that the filter
should target the output towards.RenderedTextStore
to store text snippets if no further rendering of the
all or portions of the returned content should not be performed.
execute
in interface RenderFilter
string
- the String to filterrenderContext
- the context the filter is being executed within
public java.lang.String[] getUserDocumentation(java.lang.String language)
RenderFilter
getUserDocumentation
in interface RenderFilter
language
- the language as an ISO-639 language code to return the documentation in.
protected abstract java.lang.String executePlainTextTarget(java.lang.String string, RenderContext renderContext)
RenderTarget.TARGET_PLAIN_TEXT
.
string
- the String to filterrenderContext
- the context the filter is being executed within
protected abstract java.lang.String executePlainEmailTarget(java.lang.String string, RenderContext renderContext)
RenderTarget.TARGET_PLAIN_EMAIL
.
string
- the String to filterrenderContext
- the context the filter is being executed within
protected abstract java.lang.String executeHtmlTarget(java.lang.String string, RenderContext renderContext)
RenderTarget.TARGET_HTML
.
string
- the String to filterrenderContext
- the context the filter is being executed within
protected abstract java.lang.String executeWysiwygEditorTarget(java.lang.String string, RenderContext renderContext)
RenderTarget.TARGET_WYSIWYG_EDITOR
.
string
- the String to filterrenderContext
- the context the filter is being executed within
protected abstract java.lang.String executeNoMarkupTarget(java.lang.String string, RenderContext renderContext)
RenderTarget.TARGET_NO_MARKUP
.
string
- the String to filterrenderContext
- the context the filter is being executed within
protected abstract java.util.Map getDocumentationMap()
protected abstract java.lang.String[] getDefaultHelp()
|
Jive Forums Project Page | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |