Package org.openstreetmap.josm.tools
Class XmlParsingException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- org.xml.sax.SAXException
-
- org.openstreetmap.josm.tools.XmlParsingException
-
- All Implemented Interfaces:
java.io.Serializable
public class XmlParsingException extends org.xml.sax.SAXException
An exception thrown during XML parsing, with known line and column.- Since:
- 6906
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description private intcolumnNumberprivate intlineNumber
-
Constructor Summary
Constructors Constructor Description XmlParsingException(java.lang.Exception e)Constructs a newXmlParsingException.XmlParsingException(java.lang.String message)Constructs a newXmlParsingException.XmlParsingException(java.lang.String message, java.lang.Exception e)Constructs a newXmlParsingException.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetColumnNumber()Returns the column number where the exception occurred.intgetLineNumber()Returns the line number where the exception occurred.java.lang.StringgetMessage()XmlParsingExceptionrememberLocation(org.xml.sax.Locator locator)Sets the location (line/column) where the exception occurred.
-
-
-
Field Detail
-
columnNumber
private int columnNumber
-
lineNumber
private int lineNumber
-
-
Constructor Detail
-
XmlParsingException
public XmlParsingException(java.lang.Exception e)
Constructs a newXmlParsingException.- Parameters:
e- The cause
-
XmlParsingException
public XmlParsingException(java.lang.String message, java.lang.Exception e)
Constructs a newXmlParsingException.- Parameters:
message- The error messagee- The cause
-
XmlParsingException
public XmlParsingException(java.lang.String message)
Constructs a newXmlParsingException.- Parameters:
message- The error message
-
-
Method Detail
-
rememberLocation
public XmlParsingException rememberLocation(org.xml.sax.Locator locator)
Sets the location (line/column) where the exception occurred.- Parameters:
locator- object giving the location (line/column) where the exception occurred- Returns:
this
-
getMessage
public java.lang.String getMessage()
- Overrides:
getMessagein classorg.xml.sax.SAXException
-
getColumnNumber
public int getColumnNumber()
Returns the column number where the exception occurred.- Returns:
- the column number where the exception occurred
-
getLineNumber
public int getLineNumber()
Returns the line number where the exception occurred.- Returns:
- the line number where the exception occurred
-
-