org.netbeans.spi.viewmodel/2 1.32.1

org.netbeans.spi.viewmodel
Interface TableRendererModel

All Superinterfaces:
Model
All Known Implementing Classes:
Models.CompoundModel

public interface TableRendererModel
extends Model

Model that provides custom cell renderer and cell editor for table cells.

Since:
1.28

Method Summary
 void addModelListener(ModelListener l)
          Registers given listener.
 boolean canEditCell(Object node, String columnID)
          Test whether this renderer can edit the given cell.
 boolean canRenderCell(Object node, String columnID)
          Test whether this renderer can render the given cell.
 TableCellEditor getCellEditor(Object node, String columnID)
          Get the editor of the given cell
 TableCellRenderer getCellRenderer(Object node, String columnID)
          Get the renderer of the given cell
 void removeModelListener(ModelListener l)
          Unregisters given listener.
 

Method Detail

canRenderCell

boolean canRenderCell(Object node,
                      String columnID)
                      throws UnknownTypeException
Test whether this renderer can render the given cell.

Parameters:
node - Tree node representing the row
columnID - The column name
Returns:
true if the implementation can render the given cell, false otherwise
Throws:
UnknownTypeException - If the implementation can not decide whether to render the given cell.

getCellRenderer

TableCellRenderer getCellRenderer(Object node,
                                  String columnID)
                                  throws UnknownTypeException
Get the renderer of the given cell

Parameters:
node - Tree node representing the row
columnID - The column name
Returns:
The cell renderer
Throws:
UnknownTypeException - If the implementation can not render the given cell.

canEditCell

boolean canEditCell(Object node,
                    String columnID)
                    throws UnknownTypeException
Test whether this renderer can edit the given cell.

Parameters:
node - Tree node representing the row
columnID - The column name
Returns:
true if the implementation can edit the given cell, false otherwise
Throws:
UnknownTypeException - If the implementation can not decide whether to edit the given cell.

getCellEditor

TableCellEditor getCellEditor(Object node,
                              String columnID)
                              throws UnknownTypeException
Get the editor of the given cell

Parameters:
node - Tree node representing the row
columnID - The column name
Returns:
The cell editor
Throws:
UnknownTypeException - If the implementation can not edit the given cell.

addModelListener

void addModelListener(ModelListener l)
Registers given listener.

Parameters:
l - the listener to add

removeModelListener

void removeModelListener(ModelListener l)
Unregisters given listener.

Parameters:
l - the listener to remove

org.netbeans.spi.viewmodel/2 1.32.1

Built on December 5 2011.  |  Portions Copyright 1997-2011 Sun Microsystems, Inc. All rights reserved.