Constructor
new AttributeChecker(sgmldecl, errorhandler, markupdefinitions, entitydefinitions, docinfo, resolver)
Parameters
Name | Type | Description |
---|---|---|
sgmldecl | Sgmldecl | |
errorhandler | Errorhandler | |
markupdefinitions | Markupdefinitions | |
entitydefinitions | Entitydefinitions | |
docinfo | Docinfo | |
resolver | SystemSpecificEntityResolver | only provided for determining whether being called from within a literal template being executed as separate subprocess as workaround for outdated nawk on Mac OS |
Method Index
Name | Description |
---|---|
check_attribute_array | Checks, and populates with default attribute values if appropriate, the supplied attribute array for an element or notation. |
configure | Configuration method. |
set_declaration_set_name | Sets default declaration set name to use for lookup of attribute metadata in calls to check_attribute_value(), if none was supplied on the call itself. |
Member Details
- check_attribute_array(doctype, elementtype, notationname, content_msg)
-
Checks, and populates with default attribute values if appropriate, the supplied attribute array for an element or notation.
Will call
errorhandler.error()
(recoverable error) if anything is wrong with attributes.Parameters
Name Type Description doctype string declaration set name to lookup attribute metadata in; if this is empty, the configured default declaration set name will be used
elementtype string element name on which the attributes occur
notationname string notation name having the (data) attributes (if this is non-empty, elementtype is ignored)
content_msg string string to prepend before an error message
- configure(args)
-
Configuration method.
Parameters
Name Type Description args Object.<string, string> Map of configuration properties
- set_declaration_set_name(name)
-
Sets default declaration set name to use for lookup of attribute metadata in calls to check_attribute_value(), if none was supplied on the call itself.
This can be configured only once; subsequent calls are ignored.
Parameters
Name Type Description name string declaration set name to set