public class CmsEditor extends java.lang.Object implements I_CmsWorkplaceApp, com.vaadin.navigator.ViewChangeListener, I_CmsWindowCloseListener, I_CmsHasShortcutActions
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
BACK_LINK_PREFIX
The back link prefix.
|
static java.lang.String |
PLAIN_TEXT_PREFIX
The back link prefix.
|
static java.lang.String |
RESOURCE_ID_PREFIX
The resource id state prefix.
|
static java.lang.String |
RESOURCE_PATH_PREFIX
The resource id state prefix.
|
| Constructor and Description |
|---|
CmsEditor() |
| Modifier and Type | Method and Description |
|---|---|
void |
afterViewChange(com.vaadin.navigator.ViewChangeListener.ViewChangeEvent event) |
boolean |
beforeViewChange(com.vaadin.navigator.ViewChangeListener.ViewChangeEvent event) |
static java.lang.String |
getEditState(CmsUUID resourceId,
boolean plainText,
java.lang.String backLink)
Returns the edit state for the given resource structure id.
|
static java.lang.String |
getEditStateForNew(CmsObject cms,
I_CmsResourceType resourceType,
java.lang.String contextPath,
java.lang.String modelFilePath,
boolean plainText,
java.lang.String backLink)
Returns the edit state for the given resource structure id.
|
java.util.Map<com.vaadin.event.Action,java.lang.Runnable> |
getShortcutActions()
Returns the shortcut actions.
|
void |
initUI(I_CmsAppUIContext context)
Within this method the app UI should be initialized.
|
void |
onStateChange(java.lang.String state)
Called on navigation events.
|
void |
onWindowClose()
Executed on window close.
|
static void |
openBackLink(java.lang.String backlink)
Navigates to the back link target.
|
public static final java.lang.String BACK_LINK_PREFIX
public static final java.lang.String PLAIN_TEXT_PREFIX
public static final java.lang.String RESOURCE_ID_PREFIX
public static final java.lang.String RESOURCE_PATH_PREFIX
public CmsEditor()
public static java.lang.String getEditState(CmsUUID resourceId, boolean plainText, java.lang.String backLink)
resourceId - the resource structure isplainText - if plain text/source editing is requiredbackLink - the back link locationpublic static java.lang.String getEditStateForNew(CmsObject cms, I_CmsResourceType resourceType, java.lang.String contextPath, java.lang.String modelFilePath, boolean plainText, java.lang.String backLink)
cms - the cms contextresourceType - the resource type to createcontextPath - the context pathmodelFilePath - the model file pathplainText - if plain text/source editing is requiredbackLink - the back link locationpublic static void openBackLink(java.lang.String backlink)
backlink - the back linkpublic void afterViewChange(com.vaadin.navigator.ViewChangeListener.ViewChangeEvent event)
afterViewChange in interface com.vaadin.navigator.ViewChangeListenerViewChangeListener.afterViewChange(com.vaadin.navigator.ViewChangeListener.ViewChangeEvent)public boolean beforeViewChange(com.vaadin.navigator.ViewChangeListener.ViewChangeEvent event)
beforeViewChange in interface com.vaadin.navigator.ViewChangeListenerViewChangeListener.beforeViewChange(com.vaadin.navigator.ViewChangeListener.ViewChangeEvent)public java.util.Map<com.vaadin.event.Action,java.lang.Runnable> getShortcutActions()
I_CmsHasShortcutActionsgetShortcutActions in interface I_CmsHasShortcutActionsI_CmsHasShortcutActions.getShortcutActions()public void initUI(I_CmsAppUIContext context)
I_CmsWorkplaceAppUse the context to add the app's components to the UI.
initUI in interface I_CmsWorkplaceAppcontext - the UI contextI_CmsWorkplaceApp.initUI(org.opencms.ui.apps.I_CmsAppUIContext)public void onStateChange(java.lang.String state)
I_CmsWorkplaceApponStateChange in interface I_CmsWorkplaceAppstate - the app state to showI_CmsWorkplaceApp.onStateChange(java.lang.String)public void onWindowClose()
I_CmsWindowCloseListeneronWindowClose in interface I_CmsWindowCloseListenerI_CmsWindowCloseListener.onWindowClose()