tuwien.auto.calimero.xml
Class KNXMLException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by tuwien.auto.calimero.exception.KNXException
              extended by tuwien.auto.calimero.xml.KNXMLException
All Implemented Interfaces:
java.io.Serializable

public class KNXMLException
extends KNXException

Indicates a problem with XML processing.

See Also:
Serialized Form

Constructor Summary
KNXMLException()
          Constructs a new KNXMLException without a detail message.
KNXMLException(java.lang.String s)
          Constructs a new KNXMLException with the specified detail message.
KNXMLException(java.lang.String s, java.lang.String badItem, int lineNumber)
          Constructs a new KNXMLException with the specified detail message, the problematic/erroneous processed XML item together with the line number it occurred on.
 
Method Summary
 java.lang.String getBadItem()
          Returns the processed item which caused this exception.
 int getLineNumber()
          Returns the line number in the processed resource.
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

KNXMLException

public KNXMLException()
Constructs a new KNXMLException without a detail message.


KNXMLException

public KNXMLException(java.lang.String s)
Constructs a new KNXMLException with the specified detail message.

Parameters:
s - the detail message

KNXMLException

public KNXMLException(java.lang.String s,
                      java.lang.String badItem,
                      int lineNumber)
Constructs a new KNXMLException with the specified detail message, the problematic/erroneous processed XML item together with the line number it occurred on.

Parameters:
s - the detail message
badItem - the problematic/erroneous processed XML tag, text or content
lineNumber - line number in the processed resource, 0 for no line number
Method Detail

getBadItem

public final java.lang.String getBadItem()
Returns the processed item which caused this exception.

Returns:
bad item as string, or null if no item available

getLineNumber

public final int getLineNumber()
Returns the line number in the processed resource.

The first line is referred to with line number 1.

Returns:
line number, 0 if no line number is available