NextApp Echo3 Extras
v3.0.b4

nextapp.echo.extras.app.tree
Class TreeColumn

java.lang.Object
  extended by nextapp.echo.extras.app.tree.TreeColumn
All Implemented Interfaces:
java.io.Serializable

public class TreeColumn
extends java.lang.Object
implements java.io.Serializable

A description of a single column of a Tree.

See Also:
Serialized Form

Field Summary
static java.lang.String CELL_RENDERER_CHANGED_PROPERTY
           
static java.lang.String HEADER_RENDERER_CHANGED_PROPERTY
           
static java.lang.String HEADER_VALUE_CHANGED_PROPERTY
           
static java.lang.String IDENTIFIER_CHANGED_PROPERTY
           
static java.lang.String MODEL_INDEX_CHANGED_PROPERTY
           
static java.lang.String WIDTH_CHANGED_PROPERTY
           
 
Constructor Summary
TreeColumn(int modelIndex)
          Creates a TreeColumn with the specified model index, undefined width, and undefined cell and header renderers.
TreeColumn(int modelIndex, nextapp.echo.app.Extent width)
          Creates a TreeColumn with the specified model index and width, and undefined cell and header renderers.
TreeColumn(int modelIndex, nextapp.echo.app.Extent width, TreeCellRenderer cellRenderer, TreeCellRenderer headerRenderer)
          Creates a TreeColumn with the specified model index, width, and cell and header renderers.
 
Method Summary
 void addPropertyChangeListener(java.beans.PropertyChangeListener l)
          Adds a PropertyChangeListener to be notified of property changes to the column.
 TreeCellRenderer getCellRenderer()
          Retrieves the TreeCellRenderer used to render values contained in the column.
 TreeCellRenderer getHeaderRenderer()
          Returns the TreeCellRenderer used to render the header cell of this column.
 java.lang.Object getHeaderValue()
          Returns the header value for this column.
 java.lang.Object getIdentifier()
          Returns the identifier for this column.
 int getModelIndex()
          Returns the column index of the model which this TreeColumn represents.
 nextapp.echo.app.Extent getWidth()
          Returns the width of the column.
 void removePropertyChangeListener(java.beans.PropertyChangeListener l)
          Removes a PropertyChangeListener from being notified of property changes to the column.
 void setCellRenderer(TreeCellRenderer newValue)
          Sets the TreeCellRenderer used to render values contained in the column.
 void setHeaderRenderer(TreeCellRenderer newValue)
          Sets the TreeCellRenderer used to render the header cell of this column.
 void setHeaderValue(java.lang.Object newValue)
          Sets the header value for this column.
 void setIdentifier(java.lang.Object newValue)
          Sets the identifier for this column.
 void setModelIndex(int newValue)
          Sets the index of the column in the TreeModel which this TreeColumn object represents.
 void setWidth(nextapp.echo.app.Extent newValue)
          Sets the width of the column.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CELL_RENDERER_CHANGED_PROPERTY

public static final java.lang.String CELL_RENDERER_CHANGED_PROPERTY
See Also:
Constant Field Values

HEADER_RENDERER_CHANGED_PROPERTY

public static final java.lang.String HEADER_RENDERER_CHANGED_PROPERTY
See Also:
Constant Field Values

HEADER_VALUE_CHANGED_PROPERTY

public static final java.lang.String HEADER_VALUE_CHANGED_PROPERTY
See Also:
Constant Field Values

IDENTIFIER_CHANGED_PROPERTY

public static final java.lang.String IDENTIFIER_CHANGED_PROPERTY
See Also:
Constant Field Values

MODEL_INDEX_CHANGED_PROPERTY

public static final java.lang.String MODEL_INDEX_CHANGED_PROPERTY
See Also:
Constant Field Values

WIDTH_CHANGED_PROPERTY

public static final java.lang.String WIDTH_CHANGED_PROPERTY
See Also:
Constant Field Values
Constructor Detail

TreeColumn

public TreeColumn(int modelIndex)
Creates a TreeColumn with the specified model index, undefined width, and undefined cell and header renderers.

Parameters:
modelIndex - the column index of model data visualized by this column

TreeColumn

public TreeColumn(int modelIndex,
                  nextapp.echo.app.Extent width)
Creates a TreeColumn with the specified model index and width, and undefined cell and header renderers.

Parameters:
modelIndex - the column index of model data visualized by this column
width - the column width

TreeColumn

public TreeColumn(int modelIndex,
                  nextapp.echo.app.Extent width,
                  TreeCellRenderer cellRenderer,
                  TreeCellRenderer headerRenderer)
Creates a TreeColumn with the specified model index, width, and cell and header renderers.

Parameters:
modelIndex - the column index of model data visualized by this column
width - the column width
cellRenderer - the renderer to use for rendering model values
headerRenderer - the renderer to use for rendering the header cell
Method Detail

addPropertyChangeListener

public void addPropertyChangeListener(java.beans.PropertyChangeListener l)
Adds a PropertyChangeListener to be notified of property changes to the column.

Parameters:
l - the listener to add

getCellRenderer

public TreeCellRenderer getCellRenderer()
Retrieves the TreeCellRenderer used to render values contained in the column. The value of this property may be null, in which case the tree should revert to using its default cell renderer.

Returns:
the cell renderer for this column

getHeaderRenderer

public TreeCellRenderer getHeaderRenderer()
Returns the TreeCellRenderer used to render the header cell of this column. The value of this property may be null, in which case the tree should revert to using its default cell renderer.

Returns:
the header cell renderer for this column

getHeaderValue

public java.lang.Object getHeaderValue()
Returns the header value for this column. The header value is the object that will be provided to the header renderer to produce a component that will be used as the tree header for this column.

Returns:
the header value for this column

getIdentifier

public java.lang.Object getIdentifier()
Returns the identifier for this column. Each tree column may have an identifier. Identifiers are provided as a convenience to the application developer, and are neither used nor required by the Tree component.

Returns:
the identifier for this column

getModelIndex

public int getModelIndex()
Returns the column index of the model which this TreeColumn represents. This value is independent of the column's position within the column model, such that columns may be displayed in an arbitrary order.

Returns:
the index of the column in the model

getWidth

public nextapp.echo.app.Extent getWidth()
Returns the width of the column. This property supports Extents with fixed or percentile units.

Returns:
the width

removePropertyChangeListener

public void removePropertyChangeListener(java.beans.PropertyChangeListener l)
Removes a PropertyChangeListener from being notified of property changes to the column.

Parameters:
l - the listener to remove

setCellRenderer

public void setCellRenderer(TreeCellRenderer newValue)
Sets the TreeCellRenderer used to render values contained in the column. The value of this property may be null, in which case the tree should revert to using its default cell renderer.

Parameters:
newValue - the new cell renderer

setHeaderRenderer

public void setHeaderRenderer(TreeCellRenderer newValue)
Sets the TreeCellRenderer used to render the header cell of this column. The value of this property may be null, in which case the tree should revert to using its default cell renderer.

Parameters:
newValue - the new header cell renderer

setHeaderValue

public void setHeaderValue(java.lang.Object newValue)
Sets the header value for this column. The header value is the object that will be provided to the header renderer to produce a component that will be used as the tree header for this column.

Parameters:
newValue - the new header value

setIdentifier

public void setIdentifier(java.lang.Object newValue)
Sets the identifier for this column. Each tree column may have an identifier. Identifiers are provided as a convenience to the application developer, and are neither used nor required by the Tree component.

Parameters:
newValue - The new identifier for this column.

setModelIndex

public void setModelIndex(int newValue)
Sets the index of the column in the TreeModel which this TreeColumn object represents. This value is independent of the column's position within the column model, such that columns may be displayed in an arbitrary order.

Parameters:
newValue - the index of the column in the model

setWidth

public void setWidth(nextapp.echo.app.Extent newValue)
Sets the width of the column. This property supports Extents with fixed or percentile units.

Parameters:
newValue - the new width

NextApp Echo3 Extras
v3.0.b4