Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## mars.venus
Class ToolAction

    java.lang.Object
      javax.swing.AbstractAction
          mars.venus.ToolAction

All Implemented Interfaces:
  ActionListener, Serializable, Cloneable, EventListener, Action

    public class ToolAction

extends AbstractAction

Connects a MarsTool class (class that implements MarsTool interface) to the Mars menu system by supplying the response to that tool's menu item selection.

Author:
  Pete Sanderson
See Also:
  Serialized Form

Field Summary

Fields inherited from class javax.swing.AbstractAction
`changeSupport, enabled`

Fields inherited from interface javax.swing.Action
`ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON`

Constructor Summary
`ToolAction(Class toolClass, String toolName)` Simple constructor.

Method Summary
`void` | `actionPerformed(ActionEvent e)` Response when tool's item selected from menu.

Methods inherited from class javax.swing.AbstractAction
`addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled`

Methods inherited from class java.lang.Object
`equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### ToolAction

    public ToolAction(Class toolClass,
                      String toolName)

  Simple constructor.

  Parameters:
    `toolClass` - Class object for the associated MarsTool subclass
    `toolName` - Name of this tool, for the menu.

Method Detail

### actionPerformed

    public void actionPerformed(ActionEvent e)

  Response when tool's item selected from menu. Invokes tool's action() method.

  Parameters:
    `e` - the ActionEvent that triggered this call

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD