Changeset 3049 for DataCleaner
- Timestamp:
- 01/17/12 16:18:55 (4 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
DataCleaner/trunk/core/src/main/java/org/eobjects/datacleaner/panels/MetadataPanel.java
r2595 r3049 43 43 private static final long serialVersionUID = 1L; 44 44 45 private static final String[] columnNames = new String[] { "Table", "Column", "Type", "Native type", "Size",46 " Nullable?", "Indexed?" };45 private static final String[] COLUMN_NAMES = new String[] { "Table", "Column", "Type family", "Type", "Native type", 46 "Size", "Nullable?", "Indexed?" }; 47 47 48 48 private final AnalysisJobBuilder _analysisJobBuilder; 49 private final DCTable _table; ;49 private final DCTable _table; 50 50 51 51 @Inject … … 56 56 _analysisJobBuilder.getSourceColumnListeners().add(this); 57 57 58 _table = new DCTable( columnNames);59 _table.setAlignment(5, Alignment. CENTER);58 _table = new DCTable(COLUMN_NAMES); 59 _table.setAlignment(5, Alignment.RIGHT); 60 60 _table.setAlignment(6, Alignment.CENTER); 61 _table.setAlignment(7, Alignment.CENTER); 61 62 62 63 setLayout(new BorderLayout()); … … 72 73 final Icon validIcon = ImageManager.getInstance().getImageIcon(IconUtils.STATUS_VALID, IconUtils.ICON_SIZE_SMALL); 73 74 74 DefaultTableModel model = new DefaultTableModel(columnNames, sourceColumns.size());75 final DefaultTableModel model = new DefaultTableModel(COLUMN_NAMES, sourceColumns.size()); 75 76 76 77 int i = 0; … … 80 81 model.setValueAt(column.getName(), i, 1); 81 82 model.setValueAt(inputColumn.getDataTypeFamily(), i, 2); 82 model.setValueAt(column.getNativeType(), i, 3); 83 model.setValueAt(column.getColumnSize(), i, 4); 83 model.setValueAt(column.getType(), i, 3); 84 model.setValueAt(column.getNativeType(), i, 4); 85 model.setValueAt(column.getColumnSize(), i, 5); 84 86 85 87 Boolean nullable = column.isNullable(); 86 88 if (nullable != null && nullable.booleanValue()) { 87 model.setValueAt(validIcon, i, 5);89 model.setValueAt(validIcon, i, 6); 88 90 } else { 89 model.setValueAt("", i, 5);91 model.setValueAt("", i, 6); 90 92 } 91 93 92 94 boolean indexed = column.isIndexed(); 93 95 if (indexed) { 94 model.setValueAt(validIcon, i, 6);96 model.setValueAt(validIcon, i, 7); 95 97 } else { 96 model.setValueAt("", i, 6);98 model.setValueAt("", i, 7); 97 99 } 98 100
Note: See TracChangeset
for help on using the changeset viewer.
