freemind.main

Class XMLParseException

public class XMLParseException extends RuntimeException

An XMLParseException is thrown when an error occures while parsing an XML string.

$Revision: 1.7 $
$Date: 2003/11/03 11:00:10 $

Version: $Name: FM-0-7-1 $, $Revision: 1.7 $

Author: Marc De Scheemaecker

See Also: nanoxml.XMLElement

Field Summary
static intNO_LINE
Indicates that no line number has been associated with this exception.
Constructor Summary
XMLParseException(String name, String message)
Creates an exception.
XMLParseException(String name, int lineNr, String message)
Creates an exception.
Method Summary
intgetLineNr()
Where the error occurred, or NO_LINE if the line number is unknown.

Field Detail

NO_LINE

public static final int NO_LINE
Indicates that no line number has been associated with this exception.

Constructor Detail

XMLParseException

public XMLParseException(String name, String message)
Creates an exception.

Parameters: name The name of the element where the error is located. message A message describing what went wrong.

Preconditions:
  • message != null
Postconditions:
  • getLineNr() => NO_LINE

XMLParseException

public XMLParseException(String name, int lineNr, String message)
Creates an exception.

Parameters: name The name of the element where the error is located. lineNr The number of the line in the input. message A message describing what went wrong.

Preconditions:
  • message != null
  • lineNr > 0
Postconditions:
  • getLineNr() => lineNr

Method Detail

getLineNr

public int getLineNr()
Where the error occurred, or NO_LINE if the line number is unknown.

See Also: nanoxml.XMLParseException#NO_LINE