public interface DOMErrorHandler
| org.w3c.dom.DOMErrorHandler |
DOMErrorHandler是DOM实现在报告处理XML数据时发生错误或进行其他处理(例如验证文档)时可调用的回调接口。 甲DOMErrorHandler对象可以连接到一个Document使用的“错误处理” DOMConfiguration接口。 如果在操作过程中需要报告多个错误,则传递给错误处理程序的错误的顺序和编号取决于实现。
预计使用DOM实现的应用程序将实现此接口。
另见 Document Object Model (DOM) Level 3 Core Specification 。
公共方法(Public methods) |
|
|---|---|
abstract boolean |
handleError(DOMError error) 发生错误时,在错误处理程序上调用此方法。 |
boolean handleError (DOMError error)
发生错误时,在错误处理程序上调用此方法。
如果此方法抛出异常,则认为它等于返回true 。
| 参数(Parameters) | |
|---|---|
error |
DOMError: The error object that describes the error. This object may be reused by the DOM implementation across multiple calls to the handleError method. |
| 返回(Returns) | |
|---|---|
boolean |
If the handleError method returns false, the DOM implementation should stop the current processing when possible. If the method returns true, the processing may continue depending on DOMError.severity. |