All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class jclass.table.SeriesEditor

java.lang.Object
   |
   +----java.awt.Component
           |
           +----java.awt.Container
                   |
                   +----java.awt.Panel
                           |
                           +----jclass.beans.JCTabEditor
                                   |
                                   +----jclass.table.SeriesEditor

public abstract class SeriesEditor
extends JCTabEditor
implements JCLabelValueListener, ActionListener
This editor provides the framework to edit a series in a table. Sub-class this class to edit specific property.


Variable Index

 o temp_table
Tables shows in the custom editor and it is used as a temporary copy of the actual table.
 o type
Series type used to convert the series into text for display.

Constructor Index

 o SeriesEditor()
 o SeriesEditor(int)
Constructs a series editor for the type of series.
 o SeriesEditor(int, boolean, boolean)
 o SeriesEditor(int, boolean, boolean, boolean)
Constructs a series editor for the type of series.

Method Index

 o actionPerformed(ActionEvent)
 o clearSelection()
Clear user selection.
 o columnLabelValue(JCValueEvent)
 o getAsText()
Return a string representation of the property for display.
 o getCellsOnly()
Gets the value of the CellsOnly property, which determines whether changes are applied to cells or cells and labels.
 o getJavaInitializationString()
Returns a string which is passed to the String setter of the property.
 o getLabelsOnly()
 o getSelectedCells()
Gets the user selection using the selected cells with the radio box setting.
 o init(boolean)
Initializes the layout of the custom editor.
 o makeButtonPanel()
 o makeSelectionPanel()
 o paintValue(Graphics, Rectangle)
Displays series value as string
 o resetSeries()
Clears the series value of the temp table.
 o rowLabelValue(JCValueEvent)
 o setSeries(JCTableBean)
Sets series property of the temporary table from the actual table.
 o setValue(Object)
Sets the series value for 2 cases:
  1. when temp_table is initiatied, actual table is passed in and used to set temp_table
  2. when temp_table is changed and used to change actual table.

Variables

 o temp_table
 protected JCTableBean temp_table
Tables shows in the custom editor and it is used as a temporary copy of the actual table. After user modifies this temporary table, the modified property is copied back to the actual table.

 o type
 protected int type
Series type used to convert the series into text for display.

Constructors

 o SeriesEditor
 public SeriesEditor()
 o SeriesEditor
 public SeriesEditor(int type)
Constructs a series editor for the type of series.

Parameters:
type - one of: ALIGNMENT, BOOLEAN, BORDERSIDES, BORDERTYPE, CHARHEIGHT, CHARWIDTH, COLOR, COMPONENT, DATATYPE, FONT, INT, PIXELHEIGHT, PIXELWIDTH or STRINGCASE
See Also:
init
 o SeriesEditor
 public SeriesEditor(int type,
                     boolean use_selection,
                     boolean cells_only_selection)
 o SeriesEditor
 public SeriesEditor(int type,
                     boolean use_selection,
                     boolean cells_only_selection,
                     boolean set_editable)
Constructs a series editor for the type of series.

Parameters:
type - one of: ALIGNMENT, BOOLEAN, BORDERSIDES, BORDERTYPE, CHARHEIGHT, CHARWIDTH, COLOR, COMPONENT, DATATYPE, FONT, INT, PIXELHEIGHT, PIXELWIDTH or STRINGCASE
use_selection - Indicates if the editor uses the selection panel to select cells and/or labels.
cells_only_selection - Indicates if the editor only allows cells to be selected. use_selection must be true.
set_editable - indicates if the temp table on the editor is set to non-editable initially. (default true)
See Also:
init

Methods

 o init
 public void init(boolean set_editable)
Initializes the layout of the custom editor.

Parameters:
comp - Component put into the custom editor. It should provide specific way to set the property value.
 o makeButtonPanel
 protected Panel makeButtonPanel()
 o makeSelectionPanel
 protected Panel makeSelectionPanel()
 o getCellsOnly
 public boolean getCellsOnly()
Gets the value of the CellsOnly property, which determines whether changes are applied to cells or cells and labels.

 o getLabelsOnly
 public boolean getLabelsOnly()
 o setSeries
 protected abstract void setSeries(JCTableBean t)
Sets series property of the temporary table from the actual table.

Parameters:
t - Actual table
 o setValue
 public void setValue(Object value)
Sets the series value for 2 cases:
  1. when temp_table is initiatied, actual table is passed in and used to set temp_table
  2. when temp_table is changed and used to change actual table.

Overrides:
setValue in class JCTabEditor
 o getAsText
 public String getAsText()
Return a string representation of the property for display.

Overrides:
getAsText in class JCTabEditor
 o paintValue
 public void paintValue(Graphics gc,
                        Rectangle box)
Displays series value as string

Overrides:
paintValue in class JCTabEditor
 o getJavaInitializationString
 public String getJavaInitializationString()
Returns a string which is passed to the String setter of the property.

Overrides:
getJavaInitializationString in class JCTabEditor
 o columnLabelValue
 public void columnLabelValue(JCValueEvent e)
 o rowLabelValue
 public void rowLabelValue(JCValueEvent e)
 o resetSeries
 public abstract void resetSeries()
Clears the series value of the temp table.

 o getSelectedCells
 public JCVector getSelectedCells()
Gets the user selection using the selected cells with the radio box setting. User can choose to select cells and labels, cells only, or labels only.

 o clearSelection
 public void clearSelection()
Clear user selection.

 o actionPerformed
 public void actionPerformed(ActionEvent e)

All Packages  Class Hierarchy  This Package  Previous  Next  Index