ContentHandler.startPrefixMapping(prefix, uri)
Begin the scope of a prefix-URI Namespace mapping.
The information from this event is not necessary for normal Namespace processing: the SAX XML reader will automatically replace prefixes for element and attribute names when the feature_namespaces
feature is enabled (the default).
There are cases, however, when applications need to use prefixes in character data or in attribute values, where they cannot safely be expanded automatically; the startPrefixMapping()
and endPrefixMapping()
events supply the information to the application to expand prefixes in those contexts itself, if necessary.
Note that startPrefixMapping()
and endPrefixMapping()
events are not guaranteed to be properly nested relative to each-other: all startPrefixMapping()
events will occur before the corresponding startElement()
event, and all endPrefixMapping()
events will occur after the corresponding endElement()
event, but their order is not guaranteed.
Please login to continue.