Interface HasSideNavItems
- All Superinterfaces:
com.vaadin.flow.component.HasElement,Serializable
- All Known Implementing Classes:
SideNav,SideNavItem
public interface HasSideNavItems
extends com.vaadin.flow.component.HasElement
HasSideNavItems is an interface for components used in the side
navigation item hierarchy. The implementing components can contain and manage
multiple SideNavItem instances. The interface defines methods for
adding, removing, and accessing the items within a container.- Author:
- Vaadin Ltd
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptiondefault voidaddItem(SideNavItem... items) Adds navigation menu item(s) to the menu.default voidaddItemAsFirst(SideNavItem item) Adds the given navigation item as the first child of this navigation item.default voidaddItemAtIndex(int index, SideNavItem item) Adds the given item as child of this navigation item at the specific index.default List<SideNavItem>getItems()Gets the items added to this navigation item (the children of this component that are instances ofSideNavItem).default voidremove(SideNavItem... items) Removes the menu item(s) from the menu.default voidRemoves all navigation menu items from this item.Methods inherited from interface com.vaadin.flow.component.HasElement
getElement
-
Method Details
-
getItems
Gets the items added to this navigation item (the children of this component that are instances ofSideNavItem). This doesn't include the items added to the children of this navigation item.- Returns:
- the child
SideNavIteminstances in this navigation menu - See Also:
-
removeAll
default void removeAll()Removes all navigation menu items from this item.