|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.jdom2.Content org.jdom2.Text org.apache.wiki.parser.PluginContent
public class PluginContent
Stores the contents of a plugin in a WikiDocument DOM tree.
If the RenderingManager.WYSIWYG_EDITOR_MODE is set to Boolean.TRUE in the context, then the plugin is rendered as WikiMarkup. This allows an HTML editor to work without rendering the plugin each time as well. If RenderingManager.VAR_EXECUTE_PLUGINS is set to Boolean.FALSE, then the plugin is not executed.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.jdom2.Content |
---|
org.jdom2.Content.CType |
Field Summary |
---|
Fields inherited from class org.jdom2.Text |
---|
value |
Fields inherited from class org.jdom2.Content |
---|
ctype, parent |
Constructor Summary | |
---|---|
PluginContent(String pluginName,
Map<String,String> parameters)
Creates a new DOM element with the given plugin name and a map of parameters. |
Method Summary | |
---|---|
void |
executeParse(WikiContext context)
Executes the executeParse() method. |
String |
getParameter(String name)
Returns a parameter value from the parameter map. |
Map<String,String> |
getParameters()
Returns the parameter map given in the constructor. |
String |
getPluginName()
Returns the name of the plugin invoked by the DOM element. |
String |
getText()
The main invocation for the plugin. |
String |
getValue()
Returns the rendered plugin. |
static PluginContent |
parsePluginLine(WikiContext context,
String commandline,
int pos)
Parses a plugin invocation and returns a DOM element. |
Methods inherited from class org.jdom2.Text |
---|
append, append, clone, detach, getParent, getTextNormalize, getTextTrim, normalizeString, setParent, setText, toString |
Methods inherited from class org.jdom2.Content |
---|
equals, getCType, getDocument, getNamespacesInherited, getNamespacesInScope, getNamespacesIntroduced, getParentElement, hashCode |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public PluginContent(String pluginName, Map<String,String> parameters)
pluginName
- The FQN of a plugin.parameters
- A Map of parameters.Method Detail |
---|
public String getPluginName()
public String getParameter(String name)
name
- the name of the parameter.
public Map<String,String> getParameters()
public String getValue()
getValue
in class org.jdom2.Text
public String getText()
getText
in class org.jdom2.Text
public void executeParse(WikiContext context) throws PluginException
context
- The WikiContext
PluginException
- If something goes wrong.public static PluginContent parsePluginLine(WikiContext context, String commandline, int pos) throws PluginException
context
- The WikiContextcommandline
- The line to parsepos
- The position in the stream parsing.
PluginException
- If plugin invocation is faulty
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |