Interface for an errorhandler the SGML library user must implement and supply to processing components.
Method Index
Name | Description |
---|---|
error | Called on recoverable errors. |
fatalError | Called on unrecoverable errors. |
warning | Called on warnings. |
Member Details
- error(errmsg, systemid, publicid, lineno, colno)
-
Called on recoverable errors.
Parameters
Name Type Description errmsg string Error message
systemid string System identifier of the file/resource in error, if any
publicid string Public identifier of the file/resource in error, if any
lineno number Line number of erroneous content, if any, or 0
colno number Character column number of erroneous content; always 0
- fatalError(errmsg, systemid, publicid, lineno, colno)
-
Called on unrecoverable errors.
Note: this is called on the thread, worker, or node I/O callback and in the context of the stack where the error occurred, ie. either on parsing errors triggered from I/O calls/events or where an async operation fails (on node error/exception handlers).
throw
orexit()
will be called immediately after returning control flow to the SGML library. The implementation may preempt/intercept SGML library processing in limited ways from here, but can't continue/re-enter the calling SGML processing context.Parameters
Name Type Description errmsg string Error message
systemid string System identifier of the file/resource in error, if any
publicid string Public identifier of the file/resource in error, if any
lineno number Line number of erroneous content, if any, or 0
colno number Character column number of erroneous content; always 0
- warning(errmsg, systemid, publicid, lineno, colno)
-
Called on warnings.
Parameters
Name Type Description errmsg string Error message
systemid string System identifier of the file/resource in error, if any
publicid string Public identifier of the file/resource in error, if any
lineno number Line number of erroneous content, if any, or 0
colno number Character column number of erroneous content; always 0