public class IlvMultiColumnTableModelPropertyDescriptor extends Object implements IlvTableModelPropertyDescriptor
IlvTableModelPropertyDescriptor
that lookup for value at a particular set of column indexes. The retrieved value will
always be of String
type whatever are the types in the table.Constructor and Description |
---|
IlvMultiColumnTableModelPropertyDescriptor(IlvBasicTableModelPropertyDescriptor[] descriptors,
String separator)
Creates an
IlvMultiColumnPropertyDescriptor that will lookup at the given
set of IlvBasicTableModelPropertyDescriptor . |
IlvMultiColumnTableModelPropertyDescriptor(int[] lookupColumns,
String separator)
Creates an
IlvMultiColumnPropertyDescriptor that will lookup at the given
set of column indexes to return the property value and will set it back to these indexes when
asked. |
IlvMultiColumnTableModelPropertyDescriptor(String[] lookupColumns,
String separator)
Creates an
IlvMultiColumnPropertyDescriptor that will lookup at the given
set of column names to return the property value and will set it back to these columns when
asked. |
Modifier and Type | Method and Description |
---|---|
int[] |
getColumns(TableModel model)
Returns an array with the indices of the
lookupColumns . |
Object |
getProperty(TableModel model,
int rowIndex)
Returns the value for the given
TableModel and rowIndex . |
void |
setProperty(TableModel model,
int rowIndex,
Object propertyValue)
Sets the value for the given
TableModel and rowIndex . |
public IlvMultiColumnTableModelPropertyDescriptor(int[] lookupColumns, String separator)
IlvMultiColumnPropertyDescriptor
that will lookup at the given
set of column indexes to return the property value and will set it back to these indexes when
asked. The given separator
is used to separate values found in the table for
producing the final value. Conversely the values set in the table will be taken
from the given values by tokenizing it with the separator.public IlvMultiColumnTableModelPropertyDescriptor(String[] lookupColumns, String separator)
IlvMultiColumnPropertyDescriptor
that will lookup at the given
set of column names to return the property value and will set it back to these columns when
asked. The given separator
is used to separate values found in the table.public IlvMultiColumnTableModelPropertyDescriptor(IlvBasicTableModelPropertyDescriptor[] descriptors, String separator)
IlvMultiColumnPropertyDescriptor
that will lookup at the given
set of IlvBasicTableModelPropertyDescriptor
.
The given separator
is used to separate values found in the table.public Object getProperty(TableModel model, int rowIndex)
TableModel
and rowIndex
.
The value is always of type String
.getProperty
in interface IlvTableModelPropertyDescriptor
model
- The table model.rowIndex
- The row index.public void setProperty(TableModel model, int rowIndex, Object propertyValue) throws IlvConvertException
TableModel
and rowIndex
. The
propertyValue
must be of type String
, if not it will be
converted to a String
.setProperty
in interface IlvTableModelPropertyDescriptor
model
- The table model.rowIndex
- The row index.propertyValue
- The property value.IlvConvertException
public final int[] getColumns(TableModel model)
lookupColumns
.getColumns
in interface IlvTableModelPropertyDescriptor
model
- The table model.© Copyright 2024 Rogue Wave Software, Inc., a Perforce company.. All Rights Reserved.