Details
-
Bug
-
Status: Closed
-
Minor
-
Resolution: Fixed
-
None
-
None
-
None
-
All
Description
It is impossible to create elements with the SAXOMBuilder that use a default namespace. The startPrefixMapping method always calls OMElement.declareNamespace, even when the provided prefix is "" or null. OMElement in turn creates a prefix "axis2ns1".
This is an issue when using a Castor mapping file in combination with spring-oxm.
A possible fix to this issue would be to change the startPrefixMapping method to call OMElement.declareDefaultNamespace when the provided prefix is null or "", e.g.
public void startPrefixMapping(String prefix, String uri)
throws SAXException {
if (nextElem == null)
nextElem = createNextElement(null);
if (null == prefix || "".equals(prefix))
else
{ nextElem.declareNamespace(uri, prefix); }}
Attachments
Issue Links
- relates to
-
AXIS2-3613 SOAP message contains prefix axis2ns1 for every element when converting using JAXB generated code
- Resolved