Element (@NotNull Path file) { try { return JDOMUtil.load(file); } catch (IOException | JDOMException e) { String content = null; try { content = Files.readString(file); } catch (IOException ignored) {} throw new AssertionError("cannot parse: " + content, e); } }