}
public static void loadSearchResults(final String searchResults) {
try {
final JTable table = SearchWidget.getSearchTable();
DefaultTableModel tableModel = SearchWidget.getTableModel();
final String datafile = searchResults;
final FileReader fin = new FileReader(datafile);
tableModel = CSVTableModel.createTableModel(fin, null);
if (tableModel == null) {
JOptionPane.showMessageDialog(null,
"Error Loading Search Results.", "Error",
JOptionPane.ERROR_MESSAGE);
ModelUtils.loadSearchResults(Constants.DATA_PATH
+ "search/search.blank");
return;
} else {
}
table.setModel(tableModel);
final TableColumn hiddenLink = table.getColumnModel().getColumn(3);
hiddenLink.setMinWidth(0);
hiddenLink.setPreferredWidth(0);
hiddenLink.setMaxWidth(0);
hiddenLink.setCellRenderer(new InteractiveRenderer(3));
final TableColumn hiddenIDS = table.getColumnModel().getColumn(4);
hiddenIDS.setMinWidth(0);
hiddenIDS.setPreferredWidth(0);
hiddenIDS.setMaxWidth(0);
hiddenIDS.setCellRenderer(new InteractiveRenderer(4));