Search in sources :

Example 21 with AttributeCol52

use of org.drools.workbench.models.guided.dtable.shared.model.AttributeCol52 in project drools-wb by kiegroup.

the class GuidedDecisionTableAutoFocusBuilder method populateDecisionTable.

@Override
public void populateDecisionTable(final GuidedDecisionTable52 dtable, final int maxRowCount) {
    final AttributeCol52 column = new AttributeCol52();
    column.setAttribute(GuidedDecisionTable52.AUTO_FOCUS_ATTR);
    dtable.getAttributeCols().add(column);
    if (this.values.size() < maxRowCount) {
        for (int iRow = this.values.size(); iRow < maxRowCount; iRow++) {
            this.values.add(new DTCellValue52(RuleSheetParserUtil.isStringMeaningTrue("")));
        }
    }
    addColumnData(dtable, column);
}
Also used : AttributeCol52(org.drools.workbench.models.guided.dtable.shared.model.AttributeCol52) DTCellValue52(org.drools.workbench.models.guided.dtable.shared.model.DTCellValue52)

Example 22 with AttributeCol52

use of org.drools.workbench.models.guided.dtable.shared.model.AttributeCol52 in project drools-wb by kiegroup.

the class GuidedDecisionTableDateEffectiveBuilder method populateDecisionTable.

@Override
public void populateDecisionTable(final GuidedDecisionTable52 dtable, final int maxRowCount) {
    final AttributeCol52 column = new AttributeCol52();
    column.setAttribute(GuidedDecisionTable52.DATE_EFFECTIVE_ATTR);
    dtable.getAttributeCols().add(column);
    if (this.values.size() < maxRowCount) {
        for (int iRow = this.values.size(); iRow < maxRowCount; iRow++) {
            this.values.add(new DTCellValue52(""));
        }
    }
    addColumnData(dtable, column);
}
Also used : AttributeCol52(org.drools.workbench.models.guided.dtable.shared.model.AttributeCol52) DTCellValue52(org.drools.workbench.models.guided.dtable.shared.model.DTCellValue52)

Example 23 with AttributeCol52

use of org.drools.workbench.models.guided.dtable.shared.model.AttributeCol52 in project drools-wb by kiegroup.

the class GuidedDecisionTableDateExpiresBuilder method populateDecisionTable.

@Override
public void populateDecisionTable(final GuidedDecisionTable52 dtable, final int maxRowCount) {
    final AttributeCol52 column = new AttributeCol52();
    column.setAttribute(GuidedDecisionTable52.DATE_EXPIRES_ATTR);
    dtable.getAttributeCols().add(column);
    if (this.values.size() < maxRowCount) {
        for (int iRow = this.values.size(); iRow < maxRowCount; iRow++) {
            this.values.add(new DTCellValue52(""));
        }
    }
    addColumnData(dtable, column);
}
Also used : AttributeCol52(org.drools.workbench.models.guided.dtable.shared.model.AttributeCol52) DTCellValue52(org.drools.workbench.models.guided.dtable.shared.model.DTCellValue52)

Example 24 with AttributeCol52

use of org.drools.workbench.models.guided.dtable.shared.model.AttributeCol52 in project drools-wb by kiegroup.

the class GuidedDecisionTableDurationBuilder method populateDecisionTable.

@Override
public void populateDecisionTable(final GuidedDecisionTable52 dtable, final int maxRowCount) {
    final AttributeCol52 column = new AttributeCol52();
    column.setAttribute(GuidedDecisionTable52.DURATION_ATTR);
    dtable.getAttributeCols().add(column);
    if (this.values.size() < maxRowCount) {
        for (int iRow = this.values.size(); iRow < maxRowCount; iRow++) {
            final DTCellValue52 dcv = new DTCellValue52(0);
            this.values.add(dcv);
        }
    }
    addColumnData(dtable, column);
}
Also used : AttributeCol52(org.drools.workbench.models.guided.dtable.shared.model.AttributeCol52) DTCellValue52(org.drools.workbench.models.guided.dtable.shared.model.DTCellValue52)

Example 25 with AttributeCol52

use of org.drools.workbench.models.guided.dtable.shared.model.AttributeCol52 in project drools-wb by kiegroup.

the class GuidedDecisionTableRuleflowGroupBuilder method populateDecisionTable.

@Override
public void populateDecisionTable(final GuidedDecisionTable52 dtable, final int maxRowCount) {
    final AttributeCol52 column = new AttributeCol52();
    column.setAttribute(GuidedDecisionTable52.RULEFLOW_GROUP_ATTR);
    dtable.getAttributeCols().add(column);
    if (this.values.size() < maxRowCount) {
        for (int iRow = this.values.size(); iRow < maxRowCount; iRow++) {
            this.values.add(new DTCellValue52(""));
        }
    }
    addColumnData(dtable, column);
}
Also used : AttributeCol52(org.drools.workbench.models.guided.dtable.shared.model.AttributeCol52) DTCellValue52(org.drools.workbench.models.guided.dtable.shared.model.DTCellValue52)

Aggregations

AttributeCol52 (org.drools.workbench.models.guided.dtable.shared.model.AttributeCol52)86 Test (org.junit.Test)55 DTCellValue52 (org.drools.workbench.models.guided.dtable.shared.model.DTCellValue52)30 GuidedDecisionTable52 (org.drools.workbench.models.guided.dtable.shared.model.GuidedDecisionTable52)20 BaseColumn (org.drools.workbench.models.guided.dtable.shared.model.BaseColumn)14 ArrayList (java.util.ArrayList)12 ConditionCol52 (org.drools.workbench.models.guided.dtable.shared.model.ConditionCol52)12 DescriptionCol52 (org.drools.workbench.models.guided.dtable.shared.model.DescriptionCol52)10 RowNumberCol52 (org.drools.workbench.models.guided.dtable.shared.model.RowNumberCol52)10 Pattern52 (org.drools.workbench.models.guided.dtable.shared.model.Pattern52)9 ActionInsertFactCol52 (org.drools.workbench.models.guided.dtable.shared.model.ActionInsertFactCol52)8 ActionSetFieldCol52 (org.drools.workbench.models.guided.dtable.shared.model.ActionSetFieldCol52)8 MetadataCol52 (org.drools.workbench.models.guided.dtable.shared.model.MetadataCol52)7 IOException (java.io.IOException)6 InputStream (java.io.InputStream)6 ExcelParser (org.drools.decisiontable.parser.xls.ExcelParser)6 DataListener (org.drools.template.parser.DataListener)6 ConversionResult (org.drools.workbench.models.guided.dtable.shared.conversion.ConversionResult)6 ActionCol52 (org.drools.workbench.models.guided.dtable.shared.model.ActionCol52)5 IntegerUiColumn (org.drools.workbench.screens.guided.dtable.client.widget.table.columns.IntegerUiColumn)5