public class DefaultEditorManager extends BaseModuleManager implements EditorManager
ini/jspwiki_module.xml:
<modules>
<editor name="myeditor">
<author>Janne Jalkanen</author>
<script>foo.js</script>
<stylesheet>foo.css</stylesheet>
<path>editors/myeditor.jsp</path>
</editor>
</modules>
m_engineATTR_EDITEDTEXT, EDITOR_PLAIN, EDITOR_PREVIEW, PARA_EDITOR, PROP_EDITORTYPE, REQ_EDITEDTEXTPLUGIN_RESOURCE_LOCATION| Constructor and Description |
|---|
DefaultEditorManager(Engine engine) |
| Modifier and Type | Method and Description |
|---|---|
java.lang.String[] |
getEditorList()
Returns a list of editors as Strings of editor names.
|
java.lang.String |
getEditorName(Context context)
Returns an editor for the current context.
|
java.lang.String |
getEditorPath(Context context)
Convenience method for getting the path to the editor JSP file.
|
org.apache.wiki.ui.DefaultEditorManager.WikiEditorInfo |
getModuleInfo(java.lang.String moduleName)
Returns the
WikiModuleInfo information about the provided moduleName. |
void |
initialize(Engine engine,
java.util.Properties props)
Initializes the EditorManager.
|
java.util.Collection<WikiModuleInfo> |
modules()
Returns a collection of modules currently managed by this ModuleManager.
|
checkCompatibility, modulesclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetEditedTextcheckCompatibilitypublic DefaultEditorManager(Engine engine)
public void initialize(Engine engine, java.util.Properties props)
initialize in interface Initializablepublic java.lang.String getEditorName(Context context)
Determines the editor to use by the following order of conditions: 1. Editor set in User Preferences 2. Default Editor set in jspwiki.properties
For the PREVIEW context, this method returns the "preview" editor.
getEditorName in interface EditorManagercontext - The context that is chosen.public java.lang.String[] getEditorList()
getEditorList in interface EditorManagerpublic java.lang.String getEditorPath(Context context)
getEditorPath in interface EditorManagercontext - WikiContext from where the editor name is retrieved.public java.util.Collection<WikiModuleInfo> modules()
modules in interface ModuleManagerpublic org.apache.wiki.ui.DefaultEditorManager.WikiEditorInfo getModuleInfo(java.lang.String moduleName)
WikiModuleInfo information about the provided moduleName.getModuleInfo in interface ModuleManagerCopyright (c) 2001-2022 The Apache Software Foundation. All rights reserved.