private static boolean validateExpression(Project project, String expression) {
        try {
          XPathSupport.getInstance().createXPath(null, expression, Collections.emptyList());
            return true;
        } catch (XPathSyntaxException e) {
            Messages.showErrorDialog(project, e.getMultilineMessage(), XPathBundle.message("dialog.title.xpath.syntax.error")); //NON-NLS
        } catch (JaxenException e) {
            Messages.showErrorDialog(project, e.getMessage(), XPathBundle.message("dialog.title.xpath.error"));
        }
        return false;
    }
private static boolean validateExpression(Project project, String expression)