Package org.opencms.ui.apps
Class A_CmsAttributeAwareApp
- java.lang.Object
-
- org.opencms.ui.apps.A_CmsWorkplaceApp
-
- org.opencms.ui.apps.A_CmsAttributeAwareApp
-
- All Implemented Interfaces:
I_CmsWorkplaceApp
- Direct Known Subclasses:
CmsDbImportApp
,CmsDbManager
,CmsDbRemovePubLocksApp
,CmsDbStaticExportApp
,CmsDbSynchronizationApp
,CmsModuleApp
public abstract class A_CmsAttributeAwareApp extends A_CmsWorkplaceApp
An abstract subclass of A_CmsWorkplaceApp which provides an additional way for the main component of an app (the widget returned by getComponentForState) to influence the app layout of the app itself (i.e. the parts outside the main component). This is done using two methods: getAttributesForComponent is used to extract additiona
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.opencms.ui.apps.A_CmsWorkplaceApp
A_CmsWorkplaceApp.NavEntry
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
ATTR_INFO_COMPONENT
Attribute for info.static java.lang.String
ATTR_MAIN_HEIGHT_FULL
Attribute for full height.-
Fields inherited from class org.opencms.ui.apps.A_CmsWorkplaceApp
m_infoLayout, m_rootLayout, m_uiContext, PARAM_ASSIGN, PARAM_SEPARATOR
-
-
Constructor Summary
Constructors Constructor Description A_CmsAttributeAwareApp()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected java.util.Map<java.lang.String,java.lang.Object>
getAttributesForComponent(com.vaadin.ui.Component component)
Gets the attributes from a given component.void
openSubView(java.lang.String state, boolean updateState)
Opens the requested sub view.protected void
updateAppAttributes(java.util.Map<java.lang.String,java.lang.Object> attributes)
Handles the attributes.void
updateMainComponent(com.vaadin.ui.Component comp)
Replaces the app's main component with the given component.-
Methods inherited from class org.opencms.ui.apps.A_CmsWorkplaceApp
addParamToState, addSubNavEntry, getBreadCrumbForState, getComponentForState, getLastPathLevel, getOfflineCmsObject, getParamFromState, getParamsFromState, getSubNavEntries, initUI, onStateChange, removeParamsFromState, setBreadCrumbEntries, updateBreadCrumb, updateSubNav
-
-
-
-
Field Detail
-
ATTR_INFO_COMPONENT
public static final java.lang.String ATTR_INFO_COMPONENT
Attribute for info.- See Also:
- Constant Field Values
-
ATTR_MAIN_HEIGHT_FULL
public static final java.lang.String ATTR_MAIN_HEIGHT_FULL
Attribute for full height.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
A_CmsAttributeAwareApp
public A_CmsAttributeAwareApp()
-
-
Method Detail
-
openSubView
public void openSubView(java.lang.String state, boolean updateState)
Opens the requested sub view.- Overrides:
openSubView
in classA_CmsWorkplaceApp
- Parameters:
state
- the stateupdateState
-true
to update the state URL token
-
updateMainComponent
public void updateMainComponent(com.vaadin.ui.Component comp)
Replaces the app's main component with the given component.This also handles the attributes for the component, just as if the given component was returned by an app's getComponentForState method.
- Parameters:
comp
- the component to set as the main component
-
getAttributesForComponent
protected java.util.Map<java.lang.String,java.lang.Object> getAttributesForComponent(com.vaadin.ui.Component component)
Gets the attributes from a given component.- Parameters:
component
- to read attributes from- Returns:
- map of attributes
-
updateAppAttributes
protected void updateAppAttributes(java.util.Map<java.lang.String,java.lang.Object> attributes)
Handles the attributes.- Parameters:
attributes
- to set
-
-