optimize JavaHyperlinkDetector.java