Package de.xima.fc.gui.model.designer
Class TabViewModel
java.lang.Object
de.xima.fc.gui.model.designer.TabViewModel
- All Implemented Interfaces:
Serializable
POJO model holding the data for managing the individual tabs of the new designer.
- Since:
- 7.0.0
- Author:
- XIMA MEDIA GmbH
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic TabViewModel
empty()
void
setActiveTab
(String activeTab) static TabViewModel
-
Constructor Details
-
TabViewModel
public TabViewModel(Map<String, TabModel> availableTabs, List<String> tabMenuItems, String activeTab) New POJO with the given data.- Parameters:
availableTabs
- Value returned bygetAvailableTabs()
tabMenuItems
- Value returned bygetTabMenuItems()
activeTab
- Value returned bygetActiveTab()
-
-
Method Details
-
getActiveTab
- Returns:
- ID of the tab that is currently active (displayed).
-
getAvailableTabs
- Returns:
- Tabs that are available, whether or not they are currently shown in the UI. Map between the
TabModel.getId()
and the tab itself.
-
getTabMenuItems
- Returns:
- A list of tabs shown in the tab menu in the top header bar.
-
setActiveTab
- Parameters:
activeTab
- ID of the tab that is currently active (displayed).
-
withTabs
- Parameters:
tabs
- All available tabs.- Returns:
- A new tab view model with all available tabs. The list of tab entries is set to the given tabs, the active tab is set to the first tab.
-
empty
- Returns:
- A new empty model with no available tabs and not selected tab.
-