com.quadrique.jbuildingblocks.gui
Class TableAction

java.lang.Object
  extended by javax.swing.AbstractAction
      extended by com.quadrique.jbuildingblocks.gui.ActionBase
          extended by com.quadrique.jbuildingblocks.gui.TableAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action

public abstract class TableAction
extends ActionBase

This is the base class for all the Table GUI actions.

Author:
Hervé Rivere
See Also:
Serialized Form

Field Summary
 
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
TableAction(String zActionName, String zTooltipText, String zIconName)
          constructor
 
Method Summary
 int getSelectedRowIndex()
           
 Table getTable()
           
 void newTableSelection(SelectionBaseEvent zEvent)
          this method is called whenever a new selection is performed in the table.
 void setTable(Table zTable)
           
 
Methods inherited from class com.quadrique.jbuildingblocks.gui.ActionBase
getAccelerator, getIcon, getMnemonic, getName, getTooltipText, setAccelerator, setIcon, setMnemonic, toString, updateAction
 
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.awt.event.ActionListener
actionPerformed
 

Constructor Detail

TableAction

public TableAction(String zActionName,
                   String zTooltipText,
                   String zIconName)
            throws Exception
constructor

Parameters:
zActionName - the name of the action
zTooltipText - the tooltip text to use for this action
zIconName - the name of the icon image file. The file will be loaded with the Resources class
Throws:
Exception - if an error occurs
See Also:
Resources
Method Detail

newTableSelection

public void newTableSelection(SelectionBaseEvent zEvent)
this method is called whenever a new selection is performed in the table.


getSelectedRowIndex

public int getSelectedRowIndex()
Returns:
the selected row index (-1 if none)

setTable

public void setTable(Table zTable)
Parameters:
zTable -

getTable

public Table getTable()
Returns:
table


Copyright © 2001-2009 Quadrique Corporation. All Rights Reserved.