DhCell Class

DhCell Class

This Package | All Packages

DhSection
  |
  +--DhCell
public class DhCell
extends DhSection

Creates a table cell. You can add any number of elements in any kind of layout to a cell using the add method.

Constructors
Name Description
DhCell() Creates an empty cell.
DhCell( String text ) Creates a cell with the specified text contents.

Methods
Name Description
add(DhElement e) Adds this cell to the table.
getColSpan() Returns the number of columns this cell spans.
getDataField() Returns the data field bound to this cell.
getRowSpan() Returns the number of rows this cell spans.
getTagNameID() Topic under construction.
getText() Retrieves the text of the cell.
getValue() Retrieves the numeric value displayed in the cell.
setColSpan(int span) Sets the number of columns this cell spans.
setRowSpan(int span) Determines how many rows this cell spans.
setText( String text ) Sets the text of the cell.
setValue( int i ) Sets a numeric value for the cell.

Constructors

DhCell.DhCell

Syntax 1
public DhCell();
Description

Creates an empty cell.



Syntax 2
public DhCell( String text );
Parameters
text
The text contents of the cell.
Description

Creates a cell with the specified text contents.

Methods

DhCell.add

Syntax
public synchronized void add( DhElement e );
Description

Adds this cell to the table.

DhCell.getColSpan

Syntax
public int getColSpan();
Return Value

Returns the number of columns this cell spans.

Description

Returns the number of columns this cell spans. This number is over and above what the default table layout engine determines.

DhCell.getDataField

Syntax
public synchronized String getDataField();
Return Value

Returns the column name bound to this cell, or a null string if no column name is bound.

Description

Returns the data field bound to this cell.

DhCell.getRowSpan

Syntax
public int getRowSpan();
Return Value

Returns Number of rows this cell spans.

Description

Returns the number of rows this cell spans. This number is over and above what the default table layout engine determines.

DhCell.getTagNameID

Syntax
protected int getTagNameID();
Description

Topic under construction.

DhCell.getText

Syntax
public synchronized String getText();
Return Value

Returns The cell text.

Description

Retrieves the text of the cell.

See Also
setText

DhCell.getValue

Syntax
public int getValue();
Return Value

Returns an integer value.

Description

Retrieves the numeric value displayed in the cell.

See Also
setValue, setText

DhCell.setColSpan

Syntax
public void setColSpan( int span );
Parameters
span
The number of columns this cell should span.
Description

Sets the number of columns this cell spans. This number is over and above what the default table layout engine determines.

DhCell.setRowSpan

Syntax
public void setRowSpan( int span );
Parameters
span
Number of rows this cell should span.
Description

Determines how many rows this cell spans. This number is over and above what the default table layout engine determines.

DhCell.setText

Syntax
public synchronized void setText( String text );
Parameters
text
String to display to user.
Description

Sets the text of the cell. Setting this value overwrites any previous call to setText or setValue.

DhCell.setValue

Syntax
public void setValue( int i );
Parameters
i
The int value to display in the cell.
Description

Sets a numeric value for the cell. Setting this value overwrites any previous call to setText or setValue.