Class TabViewContainer
java.lang.Object
com.vaadin.flow.component.Component
io.jmix.tabbedmode.component.viewcontainer.TabViewContainer
- All Implemented Interfaces:
com.vaadin.flow.component.AttachNotifier,com.vaadin.flow.component.DetachNotifier,com.vaadin.flow.component.HasElement,com.vaadin.flow.component.HasSize,com.vaadin.flow.component.HasStyle,ViewContainer,Serializable
@Tag("jmix-view-container")
@JsModule("./src/viewcontainer/jmix-view-container.js")
public class TabViewContainer
extends com.vaadin.flow.component.Component
implements ViewContainer, com.vaadin.flow.component.HasSize, com.vaadin.flow.component.HasStyle
Represents a UI component that acts as a container for
View instances and their associated
ViewBreadcrumbs. The TabViewContainer provides mechanisms to manage and dynamically update
views and breadcrumbs.
The container ensures that only one View can be set at a time. Adding a new view automatically
removes the existing one. Similarly, breadcrumbs when set are associated with the container and displayed
correctly using a defined slot.
- See Also:
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidadd(com.vaadin.flow.component.Component component) Returns theViewBreadcrumbsassociated with this container.View<?>getView()Returns theViewcontained in this container.protected voidremove(com.vaadin.flow.component.Component component) protected voidvoidRemoves the breadcrumbs from this container.voidRemoves theViewcontained in this container.voidsetBreadcrumbs(ViewBreadcrumbs breadcrumbs) Sets theViewBreadcrumbsfor this container.protected voidsetBreadcrumbsInternal(ViewBreadcrumbs breadcrumbs) voidSets the specifiedViewin this container.Methods inherited from class com.vaadin.flow.component.Component
addListener, findAncestor, fireEvent, from, get, getChildren, getElement, getEventBus, getId, getListeners, getLocale, getParent, getTranslation, getTranslation, getTranslation, getTranslation, getTranslation, getTranslation, getUI, hasListener, isAttached, isTemplateMapped, isVisible, onAttach, onDetach, onEnabledStateChanged, removeFromParent, scrollIntoView, scrollIntoView, set, setElement, setId, setVisibleMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.vaadin.flow.component.AttachNotifier
addAttachListenerMethods inherited from interface com.vaadin.flow.component.DetachNotifier
addDetachListenerMethods inherited from interface com.vaadin.flow.component.HasElement
getElementMethods inherited from interface com.vaadin.flow.component.HasSize
getHeight, getHeightUnit, getMaxHeight, getMaxWidth, getMinHeight, getMinWidth, getWidth, getWidthUnit, setHeight, setHeight, setHeightFull, setMaxHeight, setMaxHeight, setMaxWidth, setMaxWidth, setMinHeight, setMinHeight, setMinWidth, setMinWidth, setSizeFull, setSizeUndefined, setWidth, setWidth, setWidthFullMethods inherited from interface com.vaadin.flow.component.HasStyle
addClassName, addClassNames, getClassName, getClassNames, getStyle, hasClassName, removeClassName, removeClassNames, setClassName, setClassName
-
Field Details
-
breadcrumbs
-
view
-
-
Constructor Details
-
TabViewContainer
public TabViewContainer()
-
-
Method Details
-
getBreadcrumbs
Description copied from interface:ViewContainerReturns theViewBreadcrumbsassociated with this container.- Specified by:
getBreadcrumbsin interfaceViewContainer- Returns:
- the
ViewBreadcrumbsinstance if set, ornullif no breadcrumbs are associated
-
setBreadcrumbs
Description copied from interface:ViewContainerSets theViewBreadcrumbsfor this container.- Specified by:
setBreadcrumbsin interfaceViewContainer- Parameters:
breadcrumbs- theViewBreadcrumbsinstance to associate with this container, ornullto remove any currently associated breadcrumbs
-
setBreadcrumbsInternal
-
removeBreadcrumbs
public void removeBreadcrumbs()Description copied from interface:ViewContainerRemoves the breadcrumbs from this container.- Specified by:
removeBreadcrumbsin interfaceViewContainer
-
getView
Description copied from interface:ViewContainerReturns theViewcontained in this container.- Specified by:
getViewin interfaceViewContainer- Returns:
- the current
Viewif present, or null if no view is set
-
setView
Description copied from interface:ViewContainerSets the specifiedViewin this container.- Specified by:
setViewin interfaceViewContainer- Parameters:
view- theViewto set in this container, ornullto remove
-
removeView
public void removeView()Description copied from interface:ViewContainerRemoves theViewcontained in this container.- Specified by:
removeViewin interfaceViewContainer
-
add
protected void add(com.vaadin.flow.component.Component component) -
remove
protected void remove(com.vaadin.flow.component.Component component) -
removeAll
protected void removeAll()
-