All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class jclass.table.Table

java.lang.Object
   |
   +----java.awt.Component
           |
           +----java.awt.Container
                   |
                   +----java.awt.Panel
                           |
                           +----jclass.table.Table

public class Table
extends Panel
implements Runnable
The base class for JCTable, used by the JClass LiveTable Applet. No resource accessors are supplied. The following resouces cannot be specified for the Applet: By default, cursor tracking and cell resizing is disabled.


Variable Index

 o about
 o cellValueListeners
 o createComponentListeners
 o displayComponentListeners
 o enterCellListeners
 o labelValueListeners
 o paintListeners
 o resizeCellListeners
 o scrollListeners
 o selectListeners
 o sortListeners
 o traverseCellListeners
 o validateCellListeners
 o version

Method Index

 o addNotify()
Creates the Panel's peer.
 o convert(JCVector, int, int)
Converts the string in each cell using the cell's datatype.
 o getAbout()
Returns vendor information.
 o getAlignment(int, int)
Returns the alignment value for a cell or label.
 o getAWTLock()
Returns the object used to lock layout and repaint.
 o getBackground(int, int)
Returns the background value for a cell or label.
 o getBorderSides(int, int)
Returns the borderSides value for a cell or label.
 o getBorderType(int, int)
Returns the borderType value for a cell or label.
 o getCell(int, int)
Gets the value of a cell or label.
 o getCharHeight(int)
Returns the charHeight value of a row.
 o getCharWidth(int)
Returns the charWidth value of a column.
 o getColumnLabel(int)
Gets a column label.
 o getComponent(int, int)
 o getDatatype(int, int)
Returns the dataType value for a cell.
 o getFont(int, int)
Returns the font value for a cell or label.
 o getForeground(int, int)
Returns the foreground (text) value for a cell or label.
 o getHorizSB()
 o getParameters(Applet)
Reads the parameter values from the HTML page using the specified applet.
 o getPixelHeight(int)
Returns the pixelHeight value of a row, previously set using setPixelHeight().
 o getPixelWidth(int)
Returns the pixelWidth value of a column, previously set using setPixelWidth().
 o getPosition(Component, JCCellPosition)
Stub method required by Action.eventToCell().
 o getPosition(int, int, Point)
Returns the pixel position of a cell's top-left corner.
 o getRowLabel(int)
Gets a row label.
 o getVersion()
Returns the current product version.
 o getVertSB()
Returns the vertical scrollbar
 o isCell(int, int)
Returns true if the row and column constitute a valid cell.
 o isColumnLabel(int, int)
Returns true if the row and column constitute a valid column label.
 o isLabel(int, int)
Returns true if the row and column constitute a valid label.
 o isRowLabel(int, int)
Returns true if the row and column constitute a valid row label.
 o isSelected(int, int)
Determines whether the cell is selected.
 o isVisible(int, int)
Cchecks whether cell is visible.
 o keyDown(Event, int)
 o layout()
 o makeColumnVisible(int)
Scrolls a column so it is visible on the screen.
 o makeRowVisible(int)
Scrolls a row so it is visible on the screen.
 o makeVisible(int, int)
Scrolls a frozen or non-frozen cell or label so it is visible on the screen.
 o minimumSize()
 o mouseDown(Event, int, int)
If currently over an URL anchor, returns.

Otherwise, sorts or resizes the cell.

 o mouseDrag(Event, int, int)
 o mouseExit(Event, int, int)
Tracks the cursor if TrackCursor is true.
 o mouseMove(Event, int, int)
Tracks the cursor if TrackCursor is true.
 o mouseUp(Event, int, int)
 o paint(Graphics)
Paints the container.
 o paint(int, int)
Redraws a range of cells and/or labels if Repaint is true.
 o paint(JCCellRange)
Redraws a range of cells and/or labels if Repaint is true.
 o preferredSize()
 o printAll(Graphics)
Disables double-buffering, and calls Container.printAll
 o repaint()
Redraws the table.
 o reshape(int, int, int, int)
Reshapes the Container to the specified bounding box.
 o run()
 o setAbout(String)
Provided for beans property editors - has no effect.
 o setBackground(Color)
Sets the default background colour for the cells.
 o setComponent(int, int, Component)
Sets the component for a cell or label (not supported by Applet).
 o setForeground(Color)
Sets the default foreground colour for the cells.
 o setLayout(LayoutManager)
Sets the layout manager for this container.
 o setSeriesDefaults()
Allows subclass to override series default values in the constructor.
 o setVersion(String)
Provided for beans property editors - has no effect.
 o validate()
Validates this Container and all of the components contained within it.

Variables

 o about
 public static final String about
 o version
 public static final String version
 o cellValueListeners
 protected JCVector cellValueListeners
 o createComponentListeners
 protected JCVector createComponentListeners
 o displayComponentListeners
 protected JCVector displayComponentListeners
 o enterCellListeners
 protected JCVector enterCellListeners
 o labelValueListeners
 protected JCVector labelValueListeners
 o paintListeners
 protected JCVector paintListeners
 o resizeCellListeners
 protected JCVector resizeCellListeners
 o scrollListeners
 protected JCVector scrollListeners
 o selectListeners
 protected JCVector selectListeners
 o sortListeners
 protected JCVector sortListeners
 o traverseCellListeners
 protected JCVector traverseCellListeners
 o validateCellListeners
 protected JCVector validateCellListeners

Methods

 o setSeriesDefaults
 protected void setSeriesDefaults()
Allows subclass to override series default values in the constructor.

 o getParameters
 public void getParameters(Applet applet)
Reads the parameter values from the HTML page using the specified applet. The values will override those previously set.

See Also:
getParameter
 o getAbout
 public String getAbout()
Returns vendor information.

 o setAbout
 public void setAbout(String s)
Provided for beans property editors - has no effect.

 o getVersion
 public String getVersion()
Returns the current product version.

 o setVersion
 public void setVersion(String s)
Provided for beans property editors - has no effect.

 o isCell
 public static final boolean isCell(int row,
                                    int col)
Returns true if the row and column constitute a valid cell.

 o isLabel
 public static final boolean isLabel(int row,
                                     int col)
Returns true if the row and column constitute a valid label.

 o isColumnLabel
 public static final boolean isColumnLabel(int row,
                                           int col)
Returns true if the row and column constitute a valid column label.

 o isRowLabel
 public static final boolean isRowLabel(int row,
                                        int col)
Returns true if the row and column constitute a valid row label.

 o isSelected
 public boolean isSelected(int row,
                           int col)
Determines whether the cell is selected.

 o paint
 public void paint(Graphics gc)
Paints the container.

Overrides:
paint in class Container
 o paint
 public void paint(int row,
                   int column)
Redraws a range of cells and/or labels if Repaint is true. This method only needs to be called when the underlying data has changed and the application has to force a redraw.

 o paint
 public void paint(JCCellRange range)
Redraws a range of cells and/or labels if Repaint is true. This method only needs to be called when the underlying data has changed and the application has to force a redraw.

Parameters:
range - the range to repaint; if null, the entire table is redrawn.
 o repaint
 public void repaint()
Redraws the table.

Overrides:
repaint in class Component
 o mouseMove
 public boolean mouseMove(Event event,
                          int x,
                          int y)
Tracks the cursor if TrackCursor is true.

Overrides:
mouseMove in class Component
See Also:
setTrackCursor
 o mouseExit
 public boolean mouseExit(Event event,
                          int x,
                          int y)
Tracks the cursor if TrackCursor is true.

Overrides:
mouseExit in class Component
See Also:
setTrackCursor
 o mouseDown
 public boolean mouseDown(Event event,
                          int x,
                          int y)
If currently over an URL anchor, returns.

Otherwise, sorts or resizes the cell.

Overrides:
mouseDown in class Component
 o mouseDrag
 public boolean mouseDrag(Event event,
                          int x,
                          int y)
Overrides:
mouseDrag in class Component
 o mouseUp
 public boolean mouseUp(Event event,
                        int x,
                        int y)
Overrides:
mouseUp in class Component
 o keyDown
 public boolean keyDown(Event ev,
                        int key)
Overrides:
keyDown in class Component
 o preferredSize
 public Dimension preferredSize()
Overrides:
preferredSize in class Container
 o minimumSize
 public Dimension minimumSize()
Overrides:
minimumSize in class Container
 o getPosition
 public Point getPosition(int row,
                          int column,
                          Point pos)
Returns the pixel position of a cell's top-left corner.

Parameters:
row,column - the cell or label position to be found
pos - the object to be used to return the position, or null
Returns:
if pos is null, the position is returned; otherwise null; If the position is invalid, pos.x will be set to JCTblEnum.MAXINT (if pos is not null) and null is returned.
 o makeVisible
 public boolean makeVisible(int row,
                            int col)
Scrolls a frozen or non-frozen cell or label so it is visible on the screen.

Returns:
false if an argument is invalid
 o makeColumnVisible
 public boolean makeColumnVisible(int column)
Scrolls a column so it is visible on the screen.

Returns:
false if the column is invalid
 o makeRowVisible
 public boolean makeRowVisible(int row)
Scrolls a row so it is visible on the screen.

Returns:
false if the row is invalid
 o isVisible
 public boolean isVisible(int row,
                          int col)
Cchecks whether cell is visible.

 o getVertSB
 public TblVertScrollbar getVertSB()
Returns the vertical scrollbar

 o getHorizSB
 public TblHorizScrollbar getHorizSB()
 o getColumnLabel
 public Object getColumnLabel(int column)
Gets a column label. To get the AWT component currently in the label, call getComponent.

See Also:
getComponent
 o getRowLabel
 public Object getRowLabel(int row)
Gets a row label. To get the AWT component currently in the label, call getComponent.

See Also:
getComponent
 o getCell
 public Object getCell(int row,
                       int col)
Gets the value of a cell or label. To get the AWT component currently in the cell, call getComponent.

See Also:
getComponent
 o reshape
 public void reshape(int x,
                     int y,
                     int width,
                     int height)
Reshapes the Container to the specified bounding box.

Overrides:
reshape in class Component
 o layout
 public void layout()
Overrides:
layout in class Container
 o validate
 public void validate()
Validates this Container and all of the components contained within it.

Overrides:
validate in class Container
 o addNotify
 public void addNotify()
Creates the Panel's peer.

Overrides:
addNotify in class Panel
 o convert
 public void convert(JCVector cells,
                     int start_row,
                     int start_column)
Converts the string in each cell using the cell's datatype.

Parameters:
start_row,start_column - the location of the first cell in the cells param
See Also:
setDatatype
 o getAlignment
 public int getAlignment(int row,
                         int col)
Returns the alignment value for a cell or label.

See Also:
setAlignment
 o getBackground
 public Color getBackground(int row,
                            int col)
Returns the background value for a cell or label.

See Also:
setBackground
 o getBorderSides
 public int getBorderSides(int row,
                           int col)
Returns the borderSides value for a cell or label.

See Also:
setBorderSides
 o getBorderType
 public int getBorderType(int row,
                          int col)
Returns the borderType value for a cell or label.

See Also:
setBorderType
 o getCharHeight
 public int getCharHeight(int row)
Returns the charHeight value of a row.

Parameters:
row - the row whose height is to be returned. This may be a specific row or JCTblEnum.LABEL (get the height of column labels).
See Also:
setCharHeight
 o getComponent
 public Component getComponent(int row,
                               int col)
 o getCharWidth
 public int getCharWidth(int col)
Returns the charWidth value of a column.

Parameters:
col - the column whose width is to be returned. This may be a specific column or JCTblEnum.LABEL (get the width of row labels).
See Also:
setCharWidth
 o getDatatype
 public int getDatatype(int row,
                        int col)
Returns the dataType value for a cell.

See Also:
setDatatype
 o getFont
 public Font getFont(int row,
                     int col)
Returns the font value for a cell or label.

See Also:
setFont
 o getForeground
 public Color getForeground(int row,
                            int col)
Returns the foreground (text) value for a cell or label.

See Also:
setForeground
 o getPixelHeight
 public int getPixelHeight(int row)
Returns the pixelHeight value of a row, previously set using setPixelHeight(). To get the current row height, use getBounds().

Parameters:
row - the row whose height is to be returned. This may be a specific row or JCTblEnum.LABEL (get the height of column labels).
See Also:
getBounds, setPixelHeight
 o getPixelWidth
 public int getPixelWidth(int col)
Returns the pixelWidth value of a column, previously set using setPixelWidth(). To get the current column width, use getBounds().

Parameters:
col - the column whose width is to be returned. This may be a specific column or JCTblEnum.LABEL (get the width of row labels).
See Also:
getBounds, setPixelWidth
 o setComponent
 public void setComponent(int row,
                          int col,
                          Component comp)
Sets the component for a cell or label (not supported by Applet).

 o run
 public void run()
 o getPosition
 public JCCellPosition getPosition(Component component,
                                   JCCellPosition pos)
Stub method required by Action.eventToCell(). Always returns null, indicating that the component is not in the table. This method is overridden by JCTable.

See Also:
getPosition
 o printAll
 public void printAll(Graphics gc)
Disables double-buffering, and calls Container.printAll

Overrides:
printAll in class Component
 o setLayout
 public final void setLayout(LayoutManager mgr)
Sets the layout manager for this container. This method is overridden to prevent the layout mgr from being set.

Overrides:
setLayout in class Container
 o getAWTLock
 public Object getAWTLock()
Returns the object used to lock layout and repaint. For JDK 1.0.2, it is the object instance. For JDK 1.1, it is Component.getTreeLock()

 o setBackground
 public void setBackground(Color c)
Sets the default background colour for the cells.

Overrides:
setBackground in class Component
 o setForeground
 public void setForeground(Color c)
Sets the default foreground colour for the cells.

Overrides:
setForeground in class Component

All Packages  Class Hierarchy  This Package  Previous  Next  Index