WUI : API


org.westofj.wui.table
Class WTableColumn

java.lang.Object
  extended byorg.westofj.wui.table.WTableColumn
Direct Known Subclasses:
WTableRowNumberColumn

public class WTableColumn
extends Object

Specifies a column within a column model.

Version:
$Revision: 1.1 $, $Date: 2003/08/29 10:46:54 $
Author:
bill

Constructor Summary
WTableColumn(int columnIndex)
          Constructs a column specification with the specified index.
 
Method Summary
 int getColumnIndex()
          Returns the index into the WTableModel.
 WDisplayable getHeader()
          Returns the header of the column.
 String getHeader(WRunner runner)
          Returns the header of the column.
 Object getIdentifier()
          Returns the user assigned identifier of the column specification.
 WTableCellRenderer getRenderer()
          Returns the renderer that will render the data for this column.
 int getWidth()
           
 boolean isSelectable()
          Returns true if this column is selectable,false otherwise.
 void setHeader(String header)
          Sets the text of the column header.
 void setHeader(WDisplayable header)
          Sets the text of the column header.
 void setIdentifier(Object identifier)
          Sets the user assigned identifier of the column.
 void setRenderer(WTableCellRenderer renderer)
          Sets the renderer for the column data.
 void setSelectable(boolean isSelectable)
          Sets if the column is selectable.
 void setWidth(int i)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WTableColumn

public WTableColumn(int columnIndex)
Constructs a column specification with the specified index. The index is the column index into the WTableModel which contains the tables data.

Parameters:
columnIndex - the index of the data.
Method Detail

getColumnIndex

public int getColumnIndex()
Returns the index into the WTableModel.

Returns:
int the index into the WTableModel.

getHeader

public WDisplayable getHeader()
Returns the header of the column.

Returns:
WDisplayable the header of the column.

getHeader

public String getHeader(WRunner runner)
Returns the header of the column.

Parameters:
runner - the current runner context.
Returns:
String the header of the column.

getIdentifier

public Object getIdentifier()
Returns the user assigned identifier of the column specification.

Returns:
Object the user assigned identifier of the column specification.

getRenderer

public WTableCellRenderer getRenderer()
Returns the renderer that will render the data for this column.

Returns:
WTableCellRenderer the renderer that will render the data for this column.

isSelectable

public boolean isSelectable()
Returns true if this column is selectable,false otherwise.

Returns:
boolean

setSelectable

public void setSelectable(boolean isSelectable)
Sets if the column is selectable. True indicates that the column is selectable. False indicates that the column it not selectable.

Parameters:
isSelectable - true indicates the column is selectable, false otherwise.

setHeader

public void setHeader(String header)
Sets the text of the column header.

Parameters:
header - the text of the column header.

setHeader

public void setHeader(WDisplayable header)
Sets the text of the column header.

Parameters:
header - the text of the column header.

setIdentifier

public void setIdentifier(Object identifier)
Sets the user assigned identifier of the column.

Parameters:
identifier - the user assigned identifier of the column.

setRenderer

public void setRenderer(WTableCellRenderer renderer)
Sets the renderer for the column data.

Parameters:
renderer - the renderer for the column data.

getWidth

public int getWidth()
Returns:

setWidth

public void setWidth(int i)
Parameters:
i -

Copyright (c) 2003 West of J - All rights reserved.