Class MenuItem

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Cloneable

    public class MenuItem
    extends LinkItem
    implements java.io.Serializable, java.lang.Cloneable
    A menu item.
    Version:
    $Revision$ $Date$
    See Also:
    Serialized Form
    • Constructor Summary

      Constructors 
      Constructor Description
      MenuItem()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void addItem​(MenuItem menuItem)
      Method addItem.
      MenuItem clone()
      Method clone.
      boolean equals​(java.lang.Object other)
      Method equals.
      java.util.List<MenuItem> getItems()
      Method getItems.
      java.lang.String getRef()
      Get a reference to a pre-defined menu item, such as a report (specified by the report goal name).
      int hashCode()
      Method hashCode.
      boolean isCollapse()
      Get whether to collapse children elements of an item menu (by default).
      void removeItem​(MenuItem menuItem)
      Method removeItem.
      void setCollapse​(boolean collapse)
      Set whether to collapse children elements of an item menu (by default).
      void setItems​(java.util.List<MenuItem> items)
      Set a list of menu item.
      void setRef​(java.lang.String ref)
      Set a reference to a pre-defined menu item, such as a report (specified by the report goal name).
      java.lang.String toString()
      Method toString.
      • Methods inherited from class java.lang.Object

        finalize, getClass, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • MenuItem

        public MenuItem()
    • Method Detail

      • addItem

        public void addItem​(MenuItem menuItem)
        Method addItem.
        Parameters:
        menuItem - a menuItem object.
      • equals

        public boolean equals​(java.lang.Object other)
        Method equals.
        Overrides:
        equals in class LinkItem
        Parameters:
        other - a other object.
        Returns:
        boolean
      • getItems

        public java.util.List<MenuItem> getItems()
        Method getItems.
        Returns:
        List
      • getRef

        public java.lang.String getRef()
        Get a reference to a pre-defined menu item, such as a report (specified by the report goal name). Any elements explicitly given override those from the pre-defined reference.
        Returns:
        String
      • hashCode

        public int hashCode()
        Method hashCode.
        Overrides:
        hashCode in class LinkItem
        Returns:
        int
      • isCollapse

        public boolean isCollapse()
        Get whether to collapse children elements of an item menu (by default).
        Returns:
        boolean
      • removeItem

        public void removeItem​(MenuItem menuItem)
        Method removeItem.
        Parameters:
        menuItem - a menuItem object.
      • setCollapse

        public void setCollapse​(boolean collapse)
        Set whether to collapse children elements of an item menu (by default).
        Parameters:
        collapse - a collapse object.
      • setItems

        public void setItems​(java.util.List<MenuItem> items)
        Set a list of menu item.
        Parameters:
        items - a items object.
      • setRef

        public void setRef​(java.lang.String ref)
        Set a reference to a pre-defined menu item, such as a report (specified by the report goal name). Any elements explicitly given override those from the pre-defined reference.
        Parameters:
        ref - a ref object.
      • toString

        public java.lang.String toString()
        Method toString.
        Overrides:
        toString in class LinkItem
        Returns:
        String