Package org.opencms.ui.apps.modules
Class CmsModuleApp
java.lang.Object
org.opencms.ui.apps.A_CmsWorkplaceApp
org.opencms.ui.apps.A_CmsAttributeAwareApp
org.opencms.ui.apps.modules.CmsModuleApp
- All Implemented Interfaces:
Serializable,I_CmsCachableApp,I_CmsWorkplaceApp
Main module manager app class.
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classAdditional app attributes for the module manager.static classContains the icon constants for the module manager.static classContains the different navigation states for the module maanger.Nested classes/interfaces inherited from class org.opencms.ui.apps.A_CmsWorkplaceApp
A_CmsWorkplaceApp.NavEntry -
Field Summary
FieldsFields inherited from class org.opencms.ui.apps.A_CmsAttributeAwareApp
ATTR_INFO_COMPONENT, ATTR_MAIN_HEIGHT_FULLFields inherited from class org.opencms.ui.apps.A_CmsWorkplaceApp
m_infoLayout, m_rootLayout, m_uiContext, PARAM_ASSIGN, PARAM_SEPARATOR -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoideditModule(String moduleName) Opens the edit dialog for the given module.static voideditModule(CmsModule module, boolean isNew, String caption, Runnable callback) Opens the module editor for the given module.voideditNewModule(Runnable callback) Opens module edit dialog for a new module.protected LinkedHashMap<String, String> getBreadCrumbForState(String state) Returns the current bread crumb entries in an ordered map.protected com.vaadin.ui.ComponentgetComponentForState(String state) Returns the app component for the given state.Returns the available menu entries.protected com.vaadin.ui.ComponentGets the module table.protected StringgetReportLabel(String state) Gets the label for a given report.protected List<A_CmsWorkplaceApp.NavEntry> getSubNavEntries(String state) Returns the sub navigation entries.voidinitUI(I_CmsAppUIContext context) Within this method the app UI should be initialized.booleanReturns whether this app should be cached within the user session.voidCalled after the view is fetched from the cache.voidonStateChange(String state) Called on navigation events.voidopenModuleInfo(Set<String> name) Opens the module info dialog.voidopenReport(String newState, A_CmsReportThread thread, String label) Changes to a new sub-view and stores a report to be displayed by that subview.invalid input: '<'pinvalid input: '<'protected voidreload()Reloads the table.voidsetReport(String key, A_CmsReportThread report) Stores a report thread isntance under a given key.protected voidupdateAppAttributes(Map<String, Object> attributes) Handles the attributes.static CmsMenuItemVisibilityModeReturns VISIBILITY_ACTIVE if a module with the given name exists, and VISIBILITY_INVISIBLE otherwise.Methods inherited from class org.opencms.ui.apps.A_CmsAttributeAwareApp
getAttributesForComponent, openSubView, updateMainComponentMethods inherited from class org.opencms.ui.apps.A_CmsWorkplaceApp
addParamToState, addSubNavEntry, getLastPathLevel, getOfflineCmsObject, getParamFromState, getParamsFromState, removeParamsFromState, setBreadCrumbEntries, updateBreadCrumb, updateSubNav
-
Field Details
-
PARAM_MODULE
The 'module' parameter.- See Also:
-
-
Constructor Details
-
CmsModuleApp
public CmsModuleApp()Creates a new instance.
-
-
Method Details
-
editModule
Opens the module editor for the given module.- Parameters:
module- the edited moduleisNew- true if this is a new modulecaption- the caption for the module editor dialogcallback- the callback to call after the edit dialog is done
-
visibilityCheckHasModule
Returns VISIBILITY_ACTIVE if a module with the given name exists, and VISIBILITY_INVISIBLE otherwise.- Parameters:
name- a module name- Returns:
- the visibility
-
editModule
Opens the edit dialog for the given module.- Parameters:
moduleName- the name of the module
-
editNewModule
Opens module edit dialog for a new module.- Parameters:
callback- the callback to call after finishing
-
getMenuEntries
Returns the available menu entries.- Returns:
- the menu entries
-
initUI
Description copied from interface:I_CmsWorkplaceAppWithin this method the app UI should be initialized.Use the context to add the app's components to the UI.
- Specified by:
initUIin interfaceI_CmsWorkplaceApp- Overrides:
initUIin classA_CmsWorkplaceApp- Parameters:
context- the UI context- See Also:
-
isCachable
Description copied from interface:I_CmsCachableAppReturns whether this app should be cached within the user session.- Specified by:
isCachablein interfaceI_CmsCachableApp- Returns:
trueif the app is cachable- See Also:
-
onRestoreFromCache
Description copied from interface:I_CmsCachableAppCalled after the view is fetched from the cache.- Specified by:
onRestoreFromCachein interfaceI_CmsCachableApp- See Also:
-
onStateChange
Description copied from interface:I_CmsWorkplaceAppCalled on navigation events.- Specified by:
onStateChangein interfaceI_CmsWorkplaceApp- Overrides:
onStateChangein classA_CmsWorkplaceApp- Parameters:
state- the app state to show- See Also:
-
openModuleInfo
Opens the module info dialog.- Parameters:
name- the name of the module
-
openReport
Changes to a new sub-view and stores a report to be displayed by that subview.invalid input: '<'pinvalid input: '<'- Parameters:
newState- the new statethread- the report thread which should be displayed in the sub viewlabel- the label to display for the report
-
setReport
Stores a report thread isntance under a given key.- Parameters:
key- the keyreport- the report thread instance
-
getBreadCrumbForState
Description copied from class:A_CmsWorkplaceAppReturns the current bread crumb entries in an ordered map.- Specified by:
getBreadCrumbForStatein classA_CmsWorkplaceApp- Parameters:
state- the current state- Returns:
- bread crumb entry name by state, in case the state is empty, the entry will be disabled
- See Also:
-
getComponentForState
Description copied from class:A_CmsWorkplaceAppReturns the app component for the given state.- Specified by:
getComponentForStatein classA_CmsWorkplaceApp- Parameters:
state- the state to render- Returns:
- the app component
- See Also:
-
getModuleTable
Gets the module table.- Returns:
- the module table
-
getReportLabel
Gets the label for a given report.- Parameters:
state- the state for which to get the label- Returns:
- the label
-
reload
Reloads the table. -
updateAppAttributes
Description copied from class:A_CmsAttributeAwareAppHandles the attributes.- Overrides:
updateAppAttributesin classA_CmsAttributeAwareApp- Parameters:
attributes- to set- See Also:
-