Package org.dashbuilder.navigation
Interface NavItem
-
- All Known Subinterfaces:
NavDivider,NavGroup
- All Known Implementing Classes:
NavDividerImpl,NavGroupImpl,NavItemImpl
public interface NavItemA navigation item is a way to classify different assets, like for instance, perspectives. A tag can be referenced by other tags, either as a parent or as a child. The links between different tags creates aNavTreestructure that can be used to provide navigation services across the different assets referenced by the tags in the tree.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static classNavItem.Type
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidaccept(NavItemVisitor visitor)Entry point for visitor interfacesNavItemcloneItem()Creates a brand new copy of this itemStringgetContext()An optional string that can be used to attach contextual information, like an external reference for instance.StringgetDescription()A brief description of the item (optional, if not provided the name is used instead)StringgetId()A unique id within the sameNavTreeStringgetName()The item's nameNavGroupgetParent()Get the parent of this item (if any)NavItem.TypegetType()The item'sNavItem.TypebooleanisModifiable()Flag indicating if the item can be modified from a tree once addedvoidsetContext(String ctx)Change the item's context attributevoidsetDescription(String description)Change the item's descriptionvoidsetId(String id)Change the item's idvoidsetModifiable(boolean modifiable)Change the item's modifiable flagvoidsetName(String name)Change the item's namevoidsetParent(NavGroup parent)Change the item's parent
-
-
-
Method Detail
-
setId
void setId(String id)
Change the item's id
-
getName
String getName()
The item's name
-
setName
void setName(String name)
Change the item's name
-
getDescription
String getDescription()
A brief description of the item (optional, if not provided the name is used instead)
-
setDescription
void setDescription(String description)
Change the item's description
-
getType
NavItem.Type getType()
The item'sNavItem.Type
-
getParent
NavGroup getParent()
Get the parent of this item (if any)- Returns:
- The item this one is a child of. Or null if this is a root item
-
setParent
void setParent(NavGroup parent)
Change the item's parent
-
isModifiable
boolean isModifiable()
Flag indicating if the item can be modified from a tree once added
-
setModifiable
void setModifiable(boolean modifiable)
Change the item's modifiable flag
-
getContext
String getContext()
An optional string that can be used to attach contextual information, like an external reference for instance.
-
setContext
void setContext(String ctx)
Change the item's context attribute
-
accept
void accept(NavItemVisitor visitor)
Entry point for visitor interfaces
-
cloneItem
NavItem cloneItem()
Creates a brand new copy of this item
-
-