private DTCellValue52 cloneLimitedEntryValue( DTCellValue52 dcv ) { if ( dcv == null ) { return null; } DTCellValue52 clone = new DTCellValue52( dcv ); return clone; }
private DTCellValue52 cloneLimitedEntryValue( DTCellValue52 dcv ) { if ( dcv == null ) { return null; } DTCellValue52 clone = new DTCellValue52( dcv ); return clone; }
@Override DTCellValue52 getCurrentValue() { //GUVNOR-1960: Always return a new instance return new DTCellValue52(); }
@Override DTCellValue52 getCurrentValue() { //GUVNOR-1960: Always return a new instance return new DTCellValue52(); }
private DTCellValue52 cloneLimitedEntryValue( DTCellValue52 dcv ) { if ( dcv == null ) { return null; } DTCellValue52 clone = new DTCellValue52( dcv ); return clone; }
private static List<DTCellValue52> convertValueList( final String[] values ) { final List<DTCellValue52> convertedValues = new ArrayList<DTCellValue52>(); for ( String value : values ) { convertedValues.add( new DTCellValue52( value ) ); } return convertedValues; }
/** * Make a DTCellValue for a column * @param c * @return */ public DTCellValue52 makeNewValue( DTColumnConfig52 c ) { DataType.DataTypes type = utils.getTypeSafeType( c ); return new DTCellValue52( type, allowEmptyValues ); }
private void addLimitedEntryColumn( final ConditionCol52 c ) { final List<DTCellValue52> values = new ArrayList<DTCellValue52>(); values.add( new DTCellValue52( Boolean.TRUE ) ); values.add( new DTCellValue52( Boolean.FALSE ) ); final ColumnValues cv = new ColumnValues( columns, values, c.getDefaultValue() ); this.expandedColumns.put( c, cv ); this.columns.add( cv ); }
/** * Make a DTCellValue for a column. This overloaded method takes a Pattern52 * object as well since the ActionSetFieldCol52 column may be associated * with an unbound Pattern * @param p * @param c * @return */ public DTCellValue52 makeNewValue( Pattern52 p, ActionSetFieldCol52 c ) { DataType.DataTypes type = utils.getTypeSafeType( p, c ); return new DTCellValue52( type, allowEmptyValues ); }
private void addRowDescriptionColumn() { ColumnValues cv = new RowDescriptionColumnValues( columns, EMPTY_VALUE, new DTCellValue52() ); cv.setExpandColumn( false ); this.expandedColumns.put( model.getDescriptionCol(), cv ); this.columns.add( cv ); }
/** * Make a DTCellValue for a column. This overloaded method takes a Pattern52 * object as well since the pattern may be different to that to which the * column has been bound in the Decision Table model, i.e. when adding or * editing a column * @param p * @param c * @return */ public DTCellValue52 makeNewValue( Pattern52 p, ConditionCol52 c ) { DataType.DataTypes type = utils.getTypeSafeType( p, c ); return new DTCellValue52( type, allowEmptyValues ); }
private void addRowNumberColumn() { ColumnValues cv = new RowNumberColumnValues( columns, EMPTY_VALUE, new DTCellValue52() ); cv.setExpandColumn( false ); this.expandedColumns.put( model.getRowNumberCol(), cv ); this.columns.add( cv ); }
private void addColumn( final ActionSetFieldCol52 a ) { final ColumnValues cv = new ColumnValues( columns, EMPTY_VALUE, model.getTableFormat() == GuidedDecisionTable52.TableFormat.EXTENDED_ENTRY ? a.getDefaultValue() : new DTCellValue52( Boolean.FALSE ) ); cv.setExpandColumn( false ); this.expandedColumns.put( a, cv ); this.columns.add( cv ); }
private void addColumn( final ActionInsertFactCol52 a ) { final ColumnValues cv = new ColumnValues( columns, EMPTY_VALUE, model.getTableFormat() == GuidedDecisionTable52.TableFormat.EXTENDED_ENTRY ? a.getDefaultValue() : new DTCellValue52( Boolean.FALSE ) ); cv.setExpandColumn( false ); this.expandedColumns.put( a, cv ); this.columns.add( cv ); }
private List<CellValue<? extends Comparable<?>>> makeRowNumberColumnData( GuidedDecisionTable52 model, BaseColumn column, int colIndex ) { int dataSize = model.getData().size(); List<CellValue<? extends Comparable<?>>> columnData = new ArrayList<CellValue<? extends Comparable<?>>>( dataSize ); for ( int iRow = 0; iRow < dataSize; iRow++ ) { DTCellValue52 dcv = new DTCellValue52(); dcv.setNumericValue( iRow + 1 ); CellValue<? extends Comparable<?>> cv = cellValueFactory.convertModelCellValue( column, dcv ); columnData.add( cv ); } return columnData; }
public void onChange( ChangeEvent event ) { at.setDefaultValue( new DTCellValue52( defaultValue.getText() ) ); } } );
private ActionRetractFactCol52 makeNewActionRetractFact() { switch ( model.getTableFormat() ) { case LIMITED_ENTRY: LimitedEntryActionRetractFactCol52 ler = new LimitedEntryActionRetractFactCol52(); ler.setValue( new DTCellValue52( "" ) ); return ler; default: return new ActionRetractFactCol52(); } }
private ActionRetractFactCol52 cloneActionRetractColumn( ActionRetractFactCol52 col ) { ActionRetractFactCol52 clone = null; if ( col instanceof LimitedEntryCol ) { clone = new LimitedEntryActionRetractFactCol52(); DTCellValue52 dcv = new DTCellValue52( ( (LimitedEntryCol) col ).getValue().getStringValue() ); ( (LimitedEntryCol) clone ).setValue( dcv ); } else { clone = new ActionRetractFactCol52(); } clone.setHeader( col.getHeader() ); clone.setHideColumn( col.isHideColumn() ); return clone; }
private ActionSetFieldCol52 cloneActionSetColumn( ActionSetFieldCol52 col ) { ActionSetFieldCol52 clone = null; if ( col instanceof LimitedEntryActionSetFieldCol52 ) { clone = new LimitedEntryActionSetFieldCol52(); DTCellValue52 dcv = cloneLimitedEntryValue( ( (LimitedEntryCol) col ).getValue() ); ( (LimitedEntryCol) clone ).setValue( dcv ); } else { clone = new ActionSetFieldCol52(); } clone.setBoundName( col.getBoundName() ); clone.setFactField( col.getFactField() ); clone.setHeader( col.getHeader() ); clone.setType( col.getType() ); clone.setValueList( col.getValueList() ); clone.setUpdate( col.isUpdate() ); clone.setDefaultValue( new DTCellValue52( col.getDefaultValue() ) ); clone.setHideColumn( col.isHideColumn() ); return clone; }
private ActionInsertFactCol52 cloneActionInsertColumn( ActionInsertFactCol52 col ) { ActionInsertFactCol52 clone = null; if ( col instanceof LimitedEntryActionInsertFactCol52 ) { clone = new LimitedEntryActionInsertFactCol52(); DTCellValue52 dcv = cloneLimitedEntryValue( ( (LimitedEntryCol) col ).getValue() ); ( (LimitedEntryCol) clone ).setValue( dcv ); } else { clone = new ActionInsertFactCol52(); } clone.setBoundName( col.getBoundName() ); clone.setType( col.getType() ); clone.setFactField( col.getFactField() ); clone.setFactType( col.getFactType() ); clone.setHeader( col.getHeader() ); clone.setValueList( col.getValueList() ); clone.setDefaultValue( new DTCellValue52( col.getDefaultValue() ) ); clone.setHideColumn( col.isHideColumn() ); clone.setInsertLogical( col.isInsertLogical() ); return clone; }