void () { final OrderEntry[] orderEntries = myState.getModifiableRootModel().getOrderEntries(); boolean hasJdkOrderEntry = false; List<ClasspathTableItem<?>> items = new ArrayList<>(); for (final OrderEntry orderEntry : orderEntries) { if (orderEntry instanceof JdkOrderEntry) { hasJdkOrderEntry = true; } items.add(ClasspathTableItem.createItem(orderEntry, myContext)); } if (!hasJdkOrderEntry) { items.add(0, new InvalidJdkItem()); } setItems(items); }