|
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.macro.Preserved
com.jivesoftware.forum.renderer.macro.CodeMacro
public class CodeMacro
Macro that pretty prints java, sql and xml code fragments.
Constructor Summary | |
---|---|
CodeMacro()
|
Method Summary | |
---|---|
java.lang.String |
execute(java.lang.String body,
RenderContext renderContext)
Applies the filter to the passed in string and returns the filtered string. |
java.lang.String |
getMacroTagName()
Returns the tag name of the macro. |
java.lang.String |
getName()
Returns the unique name of the filter. |
java.util.Map |
getParameters()
Returns a Map of user provided parameters to the macro. |
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. |
boolean |
isSingleTagMacro()
Returns true is the macro has only a single tag such as {testMacro}, false if the macro should have both an opening and closing tag ({testMacro}text here{testMacro}) |
void |
setEnabled(boolean enabled)
Sets whether the filter is enabled or disabled. |
void |
setParameters(java.util.Map parameters)
Sets a map of user provided parameters for the macro to use. |
Methods inherited from class com.jivesoftware.forum.renderer.macro.Preserved |
---|
addSpecial, addSpecial, replace, toChar, toEntity |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CodeMacro()
Method Detail |
---|
public 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.public java.lang.String getMacroTagName()
RenderMacro
getMacroTagName
in interface RenderMacro
public boolean isSingleTagMacro()
RenderMacro
isSingleTagMacro
in interface RenderMacro
public java.lang.String execute(java.lang.String body, 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
execute
in interface RenderMacro
body
- the String to filterrenderContext
- the context the filter is being executed within
RenderFilter.execute(String, RenderContext)
public java.util.Map getParameters()
RenderMacro
getParameters
in interface RenderMacro
public void setParameters(java.util.Map parameters)
RenderMacro
setParameters
in interface RenderMacro
parameters
- a map of user provided parameterspublic 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.
|
Jive Forums Project Page | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |