|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.irisel.util.xml.ErrorStorer
public class ErrorStorer
The ErrorStorer maps Nodes to errors.It receives a reference to the ErrorTreeFactory in the Constructor.When error is called, it asks the ErrorTreeFactory for the current node, and uses this as the "key" of a Hashtable, with the error as a value.The error value is wrapped up nicely in an ParseError object.It is used in the XML Tutorial to illustrate how to implement the ErrorListener to provide error storage for later reference.
Constructor Summary | |
---|---|
ErrorStorer(org.apache.xerces.parsers.DOMParser parser)
Constructor |
Method Summary | |
---|---|
void |
error(org.xml.sax.SAXParseException ex)
|
void |
fatalError(org.xml.sax.SAXParseException ex)
|
ParseError |
getError(org.w3c.dom.Node node)
The ParseError object for the node key is returned.If the node doesn't have errors, null is returned. |
java.util.Hashtable<org.w3c.dom.Node,ParseError> |
getErrorNodes()
The client is is allowed to get a reference to the Hashtable, and so could corrupt it, or add to it... |
void |
resetErrors()
Reset the error storage. |
void |
warning(org.xml.sax.SAXParseException ex)
|
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ErrorStorer(org.apache.xerces.parsers.DOMParser parser)
Method Detail |
---|
public java.util.Hashtable<org.w3c.dom.Node,ParseError> getErrorNodes()
public ParseError getError(org.w3c.dom.Node node)
public void resetErrors()
public void warning(org.xml.sax.SAXParseException ex)
warning
in interface org.xml.sax.ErrorHandler
public void error(org.xml.sax.SAXParseException ex)
error
in interface org.xml.sax.ErrorHandler
public void fatalError(org.xml.sax.SAXParseException ex) throws org.xml.sax.SAXException
fatalError
in interface org.xml.sax.ErrorHandler
org.xml.sax.SAXException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |