void (@NotNull HyperlinkEvent e) { JEditorPane pane = (JEditorPane)e.getSource(); if (e instanceof HTMLFrameHyperlinkEvent) { HTMLDocument doc = (HTMLDocument)pane.getDocument(); doc.processHTMLFrameHyperlinkEvent((HTMLFrameHyperlinkEvent)e); } else { URL url = e.getURL(); if (url != null) { BrowserUtil.browse(url); } } }