|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.lang.Throwable
java.lang.Exception
net.n3.nanoxml.XMLException
net.n3.nanoxml.XMLValidationException
An XMLValidationException is thrown when the XML passed to the XML parser is well-formed but not valid.
Field Summary | |
static int |
ATTRIBUTE_WITH_INVALID_VALUE
An attribute has an invalid value. |
static int |
MISC_ERROR
Another error than those specified in this class was encountered. |
static int |
MISSING_ATTRIBUTE
An attribute was missing. |
static int |
MISSING_ELEMENT
An element was missing. |
static int |
MISSING_PCDATA
A PCDATA element was missing. |
static int |
UNEXPECTED_ATTRIBUTE
An unexpected attribute was encountered. |
static int |
UNEXPECTED_ELEMENT
An unexpected element was encountered. |
static int |
UNEXPECTED_PCDATA
An unexpected PCDATA element was encountered. |
Constructor Summary | |
XMLValidationException(int errorType,
String systemID,
int lineNr,
String elementName,
String attributeName,
String attributeValue,
String msg)
Creates a new exception. |
Method Summary | |
protected void |
finalize()
Cleans up the object when it's destroyed. |
String |
getAttributeName()
Returns the name of the attribute in which the validation is violated. |
String |
getAttributeValue()
Returns the value of the attribute in which the validation is violated. |
String |
getElementName()
Returns the name of the element in which the validation is violated. |
Methods inherited from class net.n3.nanoxml.XMLException |
getException, getLineNr, getSystemID, printStackTrace, printStackTrace, printStackTrace, toString |
Methods inherited from class java.lang.Throwable |
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, setStackTrace |
Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final int MISSING_ELEMENT
public static final int UNEXPECTED_ELEMENT
public static final int MISSING_ATTRIBUTE
public static final int UNEXPECTED_ATTRIBUTE
public static final int ATTRIBUTE_WITH_INVALID_VALUE
public static final int MISSING_PCDATA
public static final int UNEXPECTED_PCDATA
public static final int MISC_ERROR
Constructor Detail |
public XMLValidationException(int errorType, String systemID, int lineNr, String elementName, String attributeName, String attributeValue, String msg)
errorType
- the type of validity errorsystemID
- the system ID from where the data camelineNr
- the line number in the XML data where the
exception occurred.elementName
- the name of the offending elementattributeName
- the name of the offending attributeattributeValue
- the value of the offending attributemsg
- the message of the exception.Method Detail |
protected void finalize() throws Throwable
finalize
in class XMLException
Throwable
public String getElementName()
public String getAttributeName()
public String getAttributeValue()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |