public class ColumnCellRenderer
extends java.lang.Object
implements javax.swing.ListCellRenderer
Constructor and Description |
---|
ColumnCellRenderer()
Constructs a default renderer.
|
ColumnCellRenderer(javax.swing.JComboBox comboBox)
Sets up a ColumnCellRenderer for a given combo box.
|
Modifier and Type | Method and Description |
---|---|
java.awt.Component |
getListCellRendererComponent(javax.swing.JList list,
java.lang.Object value,
int index,
boolean isSelected,
boolean hasFocus) |
java.lang.Object |
mapValue(java.lang.Object value)
Provides the representation (to be displayed in the combo box)
for an object in the box's model.
|
void |
setNullRepresentation(java.lang.Object nullRep)
Sets the representation for the null item.
|
public ColumnCellRenderer(javax.swing.JComboBox comboBox)
comboBox
- box to watchpublic ColumnCellRenderer()
public java.awt.Component getListCellRendererComponent(javax.swing.JList list, java.lang.Object value, int index, boolean isSelected, boolean hasFocus)
getListCellRendererComponent
in interface javax.swing.ListCellRenderer
public java.lang.Object mapValue(java.lang.Object value)
value
- input valuepublic void setNullRepresentation(java.lang.Object nullRep)
nullRep
- null representation object to appear in combo boxCopyright © 2003-2017 CCLRC: Council for the Central Laboratory of the Research Councils. All Rights Reserved.