*/
private TableCellRenderer getHeaderRenderer() {
// Return a table renderer that displays the icon matching current sort
return new TableCellRenderer() {
private TableCellRenderer headerRenderer;
private ImageIcon ascendingSortIcon = new ImageIcon(getClass().getResource("resources/ascending.png"));
private ImageIcon descendingSortIcon = new ImageIcon(getClass().getResource("resources/descending.png"));
public Component getTableCellRendererComponent(JTable table,
Object value, boolean isSelected, boolean hasFocus, int row, int column) {
if (this.headerRenderer == null) {
this.headerRenderer = table.getTableHeader().getDefaultRenderer();