Interface Menu


public interface Menu
A menu to be displayed in the MenuBar.
  • Method Details

    • caption

      String caption()
      The caption to be displayed for the menu.
      Returns:
      The caption
    • withCaption

      Menu withCaption(String caption)
      Create a copy of Menu with a new caption.
      Parameters:
      caption - The new caption.
      Returns:
      An updated copy of Menu.
    • withMenuItems

      Menu withMenuItems(MenuItem... menuItems)
      Create a copy of Menu with one or more instances of MenuItem.
      Parameters:
      menuItems - One or more instances of MenuItem.
      Returns:
      An updated copy of Menu.
    • withMenuItems

      Menu withMenuItems(List<MenuItem> menuItems)
      Create a copy of Menu with a new list of MenuItem.
      Parameters:
      menuItems - The new list of MenuItem.
      Returns:
      An updated copy of Menu.