use of org.drools.workbench.screens.dtablexls.backend.server.conversion.builders.GuidedDecisionTableSourceBuilderDirect in project drools-wb by kiegroup.
the class GuidedDecisionTableGeneratorListener method assertValueBuildersRowData.
private void assertValueBuildersRowData() {
// new row is created the GuidedDecisionTableSourceBuilders contain sufficient row data
if (_sourceBuilders != null) {
final int rowCount = getRowCount();
final int columnCount = _sourceBuilders.size();
for (GuidedDecisionTableSourceBuilder sb : _sourceBuilders) {
if (sb instanceof GuidedDecisionTableSourceBuilderDirect) {
final GuidedDecisionTableSourceBuilderDirect sbd = (GuidedDecisionTableSourceBuilderDirect) sb;
if (sbd.getRowCount() < rowCount) {
sbd.addCellValue(rowCount, columnCount, "");
}
} else if (sb instanceof GuidedDecisionTableSourceBuilderIndirect) {
final GuidedDecisionTableSourceBuilderIndirect sbi = (GuidedDecisionTableSourceBuilderIndirect) sb;
for (ParameterizedValueBuilder pvb : sbi.getValueBuilders().values()) {
if (pvb.getColumnData().size() < rowCount) {
pvb.addCellValue(rowCount, columnCount, "");
}
}
}
}
}
}
Aggregations