|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.opencms.workplace.editors.CmsEditorActionDefault
public class CmsEditorActionDefault
Provides a method to perform a user defined action when editing a page.
| Field Summary |
|---|
| Constructor Summary | |
|---|---|
CmsEditorActionDefault()
Default constructor needed for editor action handler implementation. |
|
| Method Summary | |
|---|---|
void |
editorAction(CmsEditor editor,
CmsJspActionElement jsp)
Performs an action which is configurable in the implementation of the interface, e.g. |
String |
getButtonName()
Returns the key name of the button displayed in the editor. |
String |
getButtonUrl(CmsJspActionElement jsp,
String resourceName)
Returns the URL of the button displayed in the editor. |
String |
getEditMode(CmsObject cmsObject,
String filename,
String element,
ServletRequest req)
Checks the current edit mode. |
boolean |
isButtonActive(CmsJspActionElement jsp,
String resourceName)
Returns true if the customized button should be active, otherwise false. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CmsEditorActionDefault()
| Method Detail |
|---|
public void editorAction(CmsEditor editor,
CmsJspActionElement jsp)
throws IOException,
JspException
I_CmsEditorActionHandler
editorAction in interface I_CmsEditorActionHandlereditor - the current editor instancejsp - the JSP action element
IOException - if a redirection fails
JspException - if including a JSP failsI_CmsEditorActionHandler.editorAction(org.opencms.workplace.editors.CmsEditor, org.opencms.jsp.CmsJspActionElement)public String getButtonName()
I_CmsEditorActionHandler
getButtonName in interface I_CmsEditorActionHandlerI_CmsEditorActionHandler.getButtonName()
public String getButtonUrl(CmsJspActionElement jsp,
String resourceName)
I_CmsEditorActionHandler
getButtonUrl in interface I_CmsEditorActionHandlerjsp - the JSP action elementresourceName - the name of the edited resource
I_CmsEditorActionHandler.getButtonUrl(CmsJspActionElement, java.lang.String)
public String getEditMode(CmsObject cmsObject,
String filename,
String element,
ServletRequest req)
I_CmsEditorActionHandlerThe mode is used to select the appropriate elements for displaying the direct edit button. If the resource is displayed in online project -> editmode = null If the resource is temporary -> editmode = inactive If the resource does not belong to the current project -> editmode = inactive If the current user has no write permissions on the resource -> editmode = inactive If the resource is locked for another user -> editmode = disabled Otherwise -> editmode = enabled
getEditMode in interface I_CmsEditorActionHandlercmsObject - the cms objectfilename - name of the resourceelement - of the desired element or nullreq - the current request
I_CmsEditorActionHandler.getEditMode(org.opencms.file.CmsObject, java.lang.String, java.lang.String, javax.servlet.ServletRequest)
public boolean isButtonActive(CmsJspActionElement jsp,
String resourceName)
I_CmsEditorActionHandler
isButtonActive in interface I_CmsEditorActionHandlerjsp - the JSP action elementresourceName - the name of the edited resource
I_CmsEditorActionHandler.isButtonActive(CmsJspActionElement, java.lang.String)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||