TableCellRenderer (int row, int column) { TreePath treePath = getTree().getPathForRow(row); if (treePath == null) return super.getCellRenderer(row, column); Object node = treePath.getLastPathComponent(); @SuppressWarnings("unchecked") TableCellRenderer renderer = COLUMNS[column].getRenderer(node); return renderer == null ? super.getCellRenderer(row, column) : renderer; }