// updateFrequency = check file every x seconds static JTable showFileAsTable(File file, double updateFrequency, O dataMakingFunction) { ret showFileAsTable(null, file, updateFrequency, dataMakingFunction); } static JTable showFileAsTable(final JTable _table, File file, double updateFrequency, O dataMakingFunction) { class X { JTable table = _table; *() { Runnable load = r { O data = map(func(S s) { joinLines(" / ", s) }, loadLogicList()); if (table != null) dataToTable_uneditable(table, data); else table = showTable(tableWithToolTips(), data); }; long lastMod = logicListFile().lastModified(); call(load); awt_onFileChange(5, table, logicListFile(), lastMod, load); } } ret new X().table; }