For IntelliJ IDEA and
Android Studio


public static InvalidXMLException fromJDOM(JDOMParseException e, String documentPath) { return new InvalidXMLException(e.getMessage(), null, e.getPartialDocument(), documentPath, e.getLineNumber(), e.getLineNumber(), e.getColumnNumber(), e); }
/** * Returns the line number of the end of the text where the parse error occurred. * <p> * The first line in the document is line 1. * </p> * * @return an integer representing the line number, or -1 if the information is not available. */ public int getLineNumber() { if (getCause() instanceof JDOMParseException) { return ((JDOMParseException) getCause()).getLineNumber(); } else { return -1; } }
/** * Returns the line number of the end of the text where the parse error occurred. * <p> * The first line in the document is line 1. * </p> * * @return an integer representing the line number, or -1 if the information is not available. */ public int getLineNumber() { if (getCause() instanceof JDOMParseException) { return ((JDOMParseException) getCause()).getLineNumber(); } else { return -1; } }