Package weka.gui

# Interface MainMenuExtension

public interface MainMenuExtension
Classes implementing this interface will be displayed in the "Extensions" menu in the main GUI of Weka.

Version:
  $Revision: 8034 $
Author:
  fracpete (fracpete at waikato dot ac dot nz)

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `fillFrame(Component frame)`
  Fills the frame with life, like adding components, window listeners, setting size, location, etc.
  `ActionListener`
  `getActionListener(JFrame owner)`
  If the extension has a custom ActionListener for the menu item, then it must be returned here.
  `String`
  `getMenuTitle()`
  Returns the name of the menu item.
  `String`
  `getSubmenuTitle()`
  Returns the name of the submenu.

- ## Method Details

  - ### getSubmenuTitle

    String getSubmenuTitle()
    Returns the name of the submenu. If there is no submenu necessary then the return value is null.
    Returns:
      the title of the submenu or null if no submenu

  - ### getMenuTitle

    String getMenuTitle()
    Returns the name of the menu item.
    Returns:
      the name of the menu item.

  - ### getActionListener

    ActionListener getActionListener(JFrame owner)
    If the extension has a custom ActionListener for the menu item, then it must be returned here. Having a custom `ActionListener` also means that the component handles any frame by itself.
    Parameters:
      `owner` - the owner of potential dialogs
    Returns:
      a custom ActionListener, can be null
    See Also:
      - `fillFrame(Component)`

  - ### fillFrame

    void fillFrame(Component frame)
    Fills the frame with life, like adding components, window listeners, setting size, location, etc. The frame object can be either derived from `JFrame` or from `JInternalFrame`. This method is only called in case `getActionListener()` returns null.
    Parameters:
      `frame` - the frame object to embed components, etc.
    See Also:
      - `getActionListener(JFrame)`
      - `JFrame`
      - `JInternalFrame`