Class ParseException

All Implemented Interfaces:
Serializable, ARPErrorNumbers
Direct Known Subclasses:

public class ParseException extends SAXParseException implements ARPErrorNumbers
An exception during the RDF processing of ARP. Note: it is distinguished from an XML related exception from Xerces because while both are SAXParseException's, the latter are not ParseException's.
See Also:
  • Constructor Details

  • Method Details

    • getErrorNumber

      public int getErrorNumber()
      The error number (from ARPErrorNumbers) related to this exception.
      The error number.
    • isSyntaxError

      public boolean isSyntaxError()
      Is this error an RDF syntax error. A syntax error indicates that well-formed XML, uses RDF properties and attributes, and whitespace and XML elements, in a way that does not conform with the RDF/XML Syntax (Revised) specification. (Currently most such errors have code ARPErrorNumbers.ERR_SYNTAX_ERROR, but this may change in the future).
      True if this is a syntax error
    • promote

      public void promote()
      Intended for use within an RDFErrorHandler. This method is untested. Marks the exception to be promoted to be thrown from the parser's entry method.
    • getMessage

      public String getMessage()
      The message without location information. Use either the formatMessage method, or the SAXParseException interface, to access the location information.
      getMessage in class SAXException
      The exception message.
    • formatMessage

      public static String formatMessage(Exception e)
      Calls e.getMessage() and also accesses line and column information for SAXParseException's.
      e - The exception to describe.
      e.getMessage() possibly prepended by error location information.
    • isPromoted

      public boolean isPromoted()
    • errorCodeName

      public static String errorCodeName(int errNo)
      The string from ARPErrorNumbers associated with an integer error code
      errNo - An error code from ARPErrorNumbers.
      The field name from ARPErrorNumbers with this error number, or null
    • errorCode

      public static int errorCode(String upper)
      The integer code associated with a string from ARPErrorNumbers.
      upper - A field name from ARPErrorNumbers, (in upper case).
      The integer value or -1, if none.