Class MenuItem

    • Constructor Detail

      • MenuItem

        public MenuItem​(String label)
        default constructor
      • MenuItem

        public MenuItem​(ArrayList<MenuItem> children,
                        String label,
                        String key,
                        int level,
                        NodeType type,
                        String target,
                        String url,
                        int nbObjects,
                        boolean leaf,
                        String labelStyle,
                        MenuItem father,
                        String componentId)
        full constructor allows building menu item with all his attributes
        Parameters:
        children - the children of current menu element
        label - the label to display for current element label must be in the correct language
        key - unique key to identify the item
        level - item level in the tree menu
        type - type of node (component, space or theme)
        target - value of The HTML Target Attribute for Anchors (<a>) possible values = _blank, _self, _parent, _top.
        url - URL to call when click on a menu item
        nbObjects - number of results contained in a node
        leaf - indicates if a node is a leaf or a branch
        labelStyle - style to apply on label
        father - father node of current item
        componentId - component identifier for example "kmelia1". This attribute is used only to identify the theme component's
      • MenuItem

        public MenuItem​(String label,
                        String key,
                        int level,
                        NodeType type,
                        boolean leaf,
                        MenuItem father,
                        String componentId)
        minimal constructor allows building menu item with all essential attributes
        Parameters:
        label - the label to display for current element label must be in the correct language
        key - unique key to identify the item
        level - item level in the tree menu
        type - type of node (component, space or theme)
        leaf - indicates if a node is a leaf or a branch
        father - father node of current item
        componentId - component identifier for example "kmelia1". This attribute is used only to identify the theme component's
    • Method Detail

      • getComponentName

        public String getComponentName()
        Returns:
        the componentName
      • setComponentName

        public void setComponentName​(String componentName)
        Parameters:
        componentName - the componentName to set
      • getChildren

        public List<MenuItem> getChildren()
        Returns:
        the children
      • setChildren

        public void setChildren​(ArrayList<MenuItem> children)
        Parameters:
        children - the children to set
      • getLabel

        public String getLabel()
        Returns:
        the label
      • setLabel

        public void setLabel​(String label)
        Parameters:
        label - the label to set
      • getKey

        public String getKey()
        Returns:
        the key
      • setKey

        public void setKey​(String key)
        Parameters:
        key - the key to set
      • getLevel

        public int getLevel()
        Returns:
        the level
      • setLevel

        public void setLevel​(int level)
        Parameters:
        level - the level to set
      • getType

        public NodeType getType()
        Returns:
        the type
      • setType

        public void setType​(NodeType type)
        Parameters:
        type - the type to set
      • getTarget

        public String getTarget()
        Returns:
        the target
      • setTarget

        public void setTarget​(String target)
        Parameters:
        target - the target to set
      • getUrl

        public String getUrl()
        Returns:
        the url
      • setUrl

        public void setUrl​(String url)
        Parameters:
        url - the url to set
      • getNbObjects

        public int getNbObjects()
        Returns:
        the nbObjects
      • setNbObjects

        public void setNbObjects​(int nbObjects)
        Parameters:
        nbObjects - the nbObjects to set
      • isLeaf

        public boolean isLeaf()
        Returns:
        the leaf
      • setLeaf

        public void setLeaf​(boolean leaf)
        Parameters:
        leaf - the leaf to set
      • getLabelStyle

        public String getLabelStyle()
        Returns:
        the labelStyle
      • setLabelStyle

        public void setLabelStyle​(String labelStyle)
        Parameters:
        labelStyle - the labelStyle to set
      • getFather

        public MenuItem getFather()
        Returns:
        the father
      • setFather

        public void setFather​(MenuItem father)
        Parameters:
        father - the father to set
      • getComponentId

        public String getComponentId()
        Returns:
        the componentId
      • setComponentId

        public void setComponentId​(String componentId)
        Parameters:
        componentId - the componentId to set
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object