[
https://issues.apache.org/jira/browse/DAFFODIL-2422?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Olabusayo Kilo updated DAFFODIL-2422:
-------------------------------------
Description:
The DaffodilXMLReader reader allows you to set/get the
Namespace/Namespace-Prefixes features, but it actually doesn't implement them
when passing info to a ContentHandler, as is required by the documentation.
Since the XMLReader is expected to work with any ContentHandler, this can lead
to unexpected results. We need to update the XMLReader to send the appropriate
stuff to the ContentHandler (which within our implementation is via the
SAXInfosetOutputter), and to mimic the behavior expected of it in the
[XMLReader
Documentation|https://docs.oracle.com/javase/7/docs/api/org/xml/sax/XMLReader.html].
Please refer to the [SAX Project
namespaces|http://www.saxproject.org/namespaces.html] page as well
The table is an excerpt from the [SAX
Documentation|http://www.saxproject.org/apidoc/org/xml/sax/package-summary.html#package_description]
||Feature ID||Access||Default||Description||
|namespaces|_read/write_|true|A value of "true" indicates namespace URIs and
unprefixed local names for element and attribute names will be available.|
|namespace-prefixes|_read/write_|false|A value of "true" indicates that XML
qualified names (with prefixes) and attributes (including _xmlns*_ attributes)
will be available.|
was:
The DaffodilXMLReader reader allows you to set/get the
Namespace/Namespace-Prefixes features, but it actually doesn't implement them
when passing info to a ContentHandler, as is required by the documentation.
Since the XMLReader is expected to work with any ContentHandler, this can lead
to unexpected results. We need to update the XMLReader to send the appropriate
stuff to the ContentHandler (which within our implementation is via the
SAXInfosetOutputter), and to mimic the behavior expected of it in the
[XMLReader Documentation
title|https://docs.oracle.com/javase/7/docs/api/org/xml/sax/XMLReader.html]
The table is an excerpt from the [SAX Documentation|#package_description]]
||Feature ID||Access||Default||Description||
|namespaces|_read/write_|true|A value of "true" indicates namespace URIs and
unprefixed local names for element and attribute names will be available.|
|namespace-prefixes|_read/write_|false|A value of "true" indicates that XML
qualified names (with prefixes) and attributes (including _xmlns*_ attributes)
will be available.|
> Implement allowed features for DaffodilXMLReader/DaffodilOutputContentHandler
> ------------------------------------------------------------------------------
>
> Key: DAFFODIL-2422
> URL: https://issues.apache.org/jira/browse/DAFFODIL-2422
> Project: Daffodil
> Issue Type: Bug
> Components: API
> Reporter: Olabusayo Kilo
> Priority: Major
>
> The DaffodilXMLReader reader allows you to set/get the
> Namespace/Namespace-Prefixes features, but it actually doesn't implement them
> when passing info to a ContentHandler, as is required by the documentation.
> Since the XMLReader is expected to work with any ContentHandler, this can
> lead to unexpected results. We need to update the XMLReader to send the
> appropriate stuff to the ContentHandler (which within our implementation is
> via the SAXInfosetOutputter), and to mimic the behavior expected of it in the
> [XMLReader
> Documentation|https://docs.oracle.com/javase/7/docs/api/org/xml/sax/XMLReader.html].
> Please refer to the [SAX Project
> namespaces|http://www.saxproject.org/namespaces.html] page as well
>
> The table is an excerpt from the [SAX
> Documentation|http://www.saxproject.org/apidoc/org/xml/sax/package-summary.html#package_description]
> ||Feature ID||Access||Default||Description||
> |namespaces|_read/write_|true|A value of "true" indicates namespace URIs and
> unprefixed local names for element and attribute names will be available.|
> |namespace-prefixes|_read/write_|false|A value of "true" indicates that XML
> qualified names (with prefixes) and attributes (including _xmlns*_
> attributes) will be available.|
--
This message was sent by Atlassian Jira
(v8.3.4#803005)