}
// Initialise CellTable's Condition columns
for ( CompositeColumn< ? > cc : model.getConditions() ) {
if ( cc instanceof LimitedEntryBRLConditionColumn ) {
LimitedEntryBRLConditionColumn brl = (LimitedEntryBRLConditionColumn) cc;
DynamicColumn<BaseColumn> column = new DynamicColumn<BaseColumn>( brl,
cellFactory.getCell( brl ),
colIndex,
eventBus );
columnWidth = brl.getWidth();
column.setWidth( columnWidth <= 0 ? defaultColumnWidth : columnWidth );
column.setVisible( !brl.isHideColumn() );
columns.add( column );
data.addColumn( colIndex,
makeColumnData( model,
brl,
colIndex++ ),
column.isVisible() );
} else if ( cc instanceof BRLConditionColumn ) {
BRLConditionColumn brl = (BRLConditionColumn) cc;
for ( BRLConditionVariableColumn variable : brl.getChildColumns() ) {
DynamicColumn<BaseColumn> column = new DynamicColumn<BaseColumn>( variable,
cellFactory.getCell( variable ),
colIndex,
eventBus );
columnWidth = variable.getWidth();
column.setWidth( columnWidth <= 0 ? defaultColumnWidth : columnWidth );
column.setVisible( !variable.isHideColumn() );
columns.add( column );
data.addColumn( colIndex,
makeColumnData( model,
variable,
colIndex++ ),
column.isVisible() );
}
} else if ( cc instanceof Pattern52 ) {
Pattern52 p = (Pattern52) cc;
for ( ConditionCol52 col : p.getChildColumns() ) {
DynamicColumn<BaseColumn> column = new DynamicColumn<BaseColumn>( col,
cellFactory.getCell( col ),
colIndex,
eventBus );
columnWidth = col.getWidth();
column.setWidth( columnWidth <= 0 ? defaultColumnWidth : columnWidth );
column.setVisible( !col.isHideColumn() );
columns.add( column );
data.addColumn( colIndex,
makeColumnData( model,
col,
colIndex++ ),
column.isVisible() );
}
}
}
// Initialise CellTable's Action columns
for ( ActionCol52 col : model.getActionCols() ) {
if ( col instanceof LimitedEntryBRLActionColumn ) {
LimitedEntryBRLActionColumn brl = (LimitedEntryBRLActionColumn) col;
DynamicColumn<BaseColumn> column = new DynamicColumn<BaseColumn>( brl,
cellFactory.getCell( brl ),
colIndex,
eventBus );
columnWidth = brl.getWidth();
column.setWidth( columnWidth <= 0 ? defaultColumnWidth : columnWidth );
column.setVisible( !brl.isHideColumn() );
columns.add( column );
data.addColumn( colIndex,
makeColumnData( model,
brl,
colIndex++ ),
column.isVisible() );
} else if ( col instanceof BRLActionColumn ) {
BRLActionColumn brl = (BRLActionColumn) col;
for ( BRLActionVariableColumn variable : brl.getChildColumns() ) {
DynamicColumn<BaseColumn> column = new DynamicColumn<BaseColumn>( variable,
cellFactory.getCell( variable ),
colIndex,
eventBus );
columnWidth = variable.getWidth();