org.opennms.bb.eui.operator.components
Class BBActionRenderer

java.lang.Object
  |
  +--org.opennms.bb.eui.operator.components.BBActionRenderer
All Implemented Interfaces:
Observer, TableCellRenderer

public class BBActionRenderer
extends Object
implements TableCellRenderer, Observer

BBActionRenderer creates a button as the renderer component instead of the default label It extends the DefaultCellEditor and overrides the appropriate methods

Author:
Jacinta

Field Summary
(package private)  boolean buttonEnabled
           
(package private)  String buttonLabel
           
(package private)  JButton selected
           
(package private)  String tasktoPerform
           
 
Constructor Summary
BBActionRenderer()
          Creates the action renderer and the button that is the renderer component
 
Method Summary
 JButton getButton()
          Returns the button used to render this cell
 Component getTableCellRendererComponent(JTable table, Object value, boolean isSelected, boolean hasFocus, int row, int col)
          Overrides the method in the the parent class and returns the the renderer component(this)
 JTextField getTextField()
          Returns the button used to render this cell
 String getValue()
           
 void update(Observable evp, Object o)
           
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

selected

JButton selected

tasktoPerform

String tasktoPerform

buttonLabel

String buttonLabel

buttonEnabled

boolean buttonEnabled
Constructor Detail

BBActionRenderer

public BBActionRenderer()
Creates the action renderer and the button that is the renderer component
Method Detail

getTableCellRendererComponent

public Component getTableCellRendererComponent(JTable table,
                                               Object value,
                                               boolean isSelected,
                                               boolean hasFocus,
                                               int row,
                                               int col)
Overrides the method in the the parent class and returns the the renderer component(this)
Specified by:
getTableCellRendererComponent in interface TableCellRenderer

update

public void update(Observable evp,
                   Object o)
Specified by:
update in interface Observer

getButton

public JButton getButton()
Returns the button used to render this cell
Returns:
the button used to render this cell

getTextField

public JTextField getTextField()
Returns the button used to render this cell
Returns:
the button used to render this cell

getValue

public String getValue()