Object (int rowIndex, int columnIndex) { final Couple<String> pair = myMacros.get(rowIndex); return switch (columnIndex) { case NAME_COLUMN -> pair.getFirst(); case VALUE_COLUMN -> pair.getSecond(); default -> { LOG.error("Wrong indices"); yield null; } }; }